Make the heat methods not crash.
This commit is contained in:
parent
37e35d5943
commit
00fa5ccbe6
1 changed files with 19 additions and 4 deletions
|
@ -223,7 +223,11 @@ public class TileEntityReactorPort extends TileEntityReactorBlock implements IFl
|
||||||
@Override
|
@Override
|
||||||
public double getTemp()
|
public double getTemp()
|
||||||
{
|
{
|
||||||
return getReactor().getTemp();
|
if(getReactor() != null)
|
||||||
|
{
|
||||||
|
return getReactor().getTemp();
|
||||||
|
}
|
||||||
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
@ -235,13 +239,20 @@ public class TileEntityReactorPort extends TileEntityReactorBlock implements IFl
|
||||||
@Override
|
@Override
|
||||||
public double getInsulationCoefficient(ForgeDirection side)
|
public double getInsulationCoefficient(ForgeDirection side)
|
||||||
{
|
{
|
||||||
return getReactor().getInsulationCoefficient(side);
|
if(getReactor() != null)
|
||||||
|
{
|
||||||
|
return getReactor().getInsulationCoefficient(side);
|
||||||
|
}
|
||||||
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void transferHeatTo(double heat)
|
public void transferHeatTo(double heat)
|
||||||
{
|
{
|
||||||
getReactor().transferHeatTo(heat);
|
if(getReactor() != null)
|
||||||
|
{
|
||||||
|
getReactor().transferHeatTo(heat);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
@ -253,7 +264,11 @@ public class TileEntityReactorPort extends TileEntityReactorBlock implements IFl
|
||||||
@Override
|
@Override
|
||||||
public double applyTemperatureChange()
|
public double applyTemperatureChange()
|
||||||
{
|
{
|
||||||
return getReactor().applyTemperatureChange();
|
if(getReactor() != null)
|
||||||
|
{
|
||||||
|
return getReactor().applyTemperatureChange();
|
||||||
|
}
|
||||||
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
|
Loading…
Add table
Reference in a new issue