Fix for the Essentia Generators Crash

Missed a server side check
This commit is contained in:
Tombenpotter committed 2014-03-30 21:30:24 +02:00
1 parent 22f5fe3ce5
commit f4c80838a4
5 files changed
+5 -5

No files matched your search

@@ -45,7 +45,7 @@ public class TileEntityArborGenerator extends TileEntity
if (waitTime <= 0)
{
if (EssentiaHandler.drainEssentia(this, Aspect.TREE, ForgeDirection.UNKNOWN, 8))
if ((!this.worldObj.isRemote) && (EssentiaHandler.drainEssentia(this, Aspect.TREE, ForgeDirection.UNKNOWN, 8)))
{
energySource.addEnergy(Config.arborGenOutput);
}
@@ -45,7 +45,7 @@ public class TileEntityAuramGenerator extends TileEntity
if (waitTime <= 0)
{
if (EssentiaHandler.drainEssentia(this, Aspect.AURA, ForgeDirection.UNKNOWN, 8))
if ((!this.worldObj.isRemote) && (EssentiaHandler.drainEssentia(this, Aspect.AURA, ForgeDirection.UNKNOWN, 8)))
{
energySource.addEnergy(Config.auramGenOutput);
}
@@ -45,7 +45,7 @@ public class TileEntityIgnisGenerator extends TileEntity
if (waitTime <= 0)
{
if (EssentiaHandler.drainEssentia(this, Aspect.FIRE, ForgeDirection.UNKNOWN, 8))
if ((!this.worldObj.isRemote) && (EssentiaHandler.drainEssentia(this, Aspect.FIRE, ForgeDirection.UNKNOWN, 8)))
{
energySource.addEnergy(6000);
}
@@ -46,7 +46,7 @@ public class TileEntityPotentiaGenerator extends TileEntity
if (waitTime <= 0)
{
if (EssentiaHandler.drainEssentia(this, Aspect.ENERGY, ForgeDirection.UNKNOWN, 8))
if ((!this.worldObj.isRemote) && (EssentiaHandler.drainEssentia(this, Aspect.ENERGY, ForgeDirection.UNKNOWN, 8)))
{
energySource.addEnergy(Config.potentiaGenOutput);
}
@@ -45,7 +45,7 @@ public class TileEntitySaxumGenerator extends TileEntity
if (waitTime <= 0)
{
if (EssentiaHandler.drainEssentia(this, Aspect.STONE, ForgeDirection.UNKNOWN, 8))
if ((!this.worldObj.isRemote) && (EssentiaHandler.drainEssentia(this, Aspect.STONE, ForgeDirection.UNKNOWN, 8)))
{
energySource.addEnergy(Config.arborGenOutput);
}