mirror of
https://github.com/Ellpeck/ActuallyAdditions.git
synced 2024-11-22 15:18:34 +01:00
Fixed a Crash with the Greenhouse Glass.
Closes https://github.com/Ellpeck/ActuallyAdditions/issues/30
This commit is contained in:
parent
46ad9fee6f
commit
2cd7bea732
1 changed files with 6 additions and 4 deletions
|
@ -31,6 +31,7 @@ public class TileEntityGreenhouseGlass extends TileEntityBase{
|
|||
this.timeUntilNextFert--;
|
||||
if(timeUntilNextFert <= 0){
|
||||
WorldPos blockToFert = this.blockToFertilize();
|
||||
if(this.blockToFertilize() != null){
|
||||
int metaBefore = blockToFert.getMetadata();
|
||||
worldObj.getBlock(blockToFert.getX(), blockToFert.getY(), blockToFert.getZ()).updateTick(worldObj, blockToFert.getX(), blockToFert.getY(), blockToFert.getZ(), Util.RANDOM);
|
||||
|
||||
|
@ -39,6 +40,7 @@ public class TileEntityGreenhouseGlass extends TileEntityBase{
|
|||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
else{
|
||||
int time = 300;
|
||||
this.timeUntilNextFert = time+Util.RANDOM.nextInt(time);
|
||||
|
|
Loading…
Reference in a new issue