From 28d27ea663a97264d9f91cdb1dee719898d6b361 Mon Sep 17 00:00:00 2001 From: Unknown Date: Sun, 13 May 2018 16:38:51 +0200 Subject: [PATCH] Fixed invalid laser tree farm ignoring extra laser mediums at boot --- .../java/cr0s/warpdrive/block/TileEntityAbstractLaser.java | 6 ++++++ .../warpdrive/block/collection/TileEntityAbstractMiner.java | 5 +++-- 2 files changed, 9 insertions(+), 2 deletions(-) diff --git a/src/main/java/cr0s/warpdrive/block/TileEntityAbstractLaser.java b/src/main/java/cr0s/warpdrive/block/TileEntityAbstractLaser.java index 26f3b4f7..e3a07bec 100644 --- a/src/main/java/cr0s/warpdrive/block/TileEntityAbstractLaser.java +++ b/src/main/java/cr0s/warpdrive/block/TileEntityAbstractLaser.java @@ -44,6 +44,12 @@ public abstract class TileEntityAbstractLaser extends TileEntityAbstractInterfac }); } + @Override + protected void onFirstUpdateTick() { + super.onFirstUpdateTick(); + updateLaserMediumDirection(); + } + @Override public void updateEntity() { super.updateEntity(); diff --git a/src/main/java/cr0s/warpdrive/block/collection/TileEntityAbstractMiner.java b/src/main/java/cr0s/warpdrive/block/collection/TileEntityAbstractMiner.java index 15e3f5a0..88356c97 100644 --- a/src/main/java/cr0s/warpdrive/block/collection/TileEntityAbstractMiner.java +++ b/src/main/java/cr0s/warpdrive/block/collection/TileEntityAbstractMiner.java @@ -18,6 +18,7 @@ import net.minecraft.nbt.NBTTagCompound; import net.minecraftforge.common.util.ForgeDirection; public abstract class TileEntityAbstractMiner extends TileEntityAbstractLaser { + // machine type protected ForgeDirection laserOutputSide = ForgeDirection.NORTH; @@ -32,8 +33,8 @@ public abstract class TileEntityAbstractMiner extends TileEntityAbstractLaser { } @Override - public void validate() { - super.validate(); + protected void onFirstUpdateTick() { + super.onFirstUpdateTick(); laserOutput = new Vector3(this).translate(0.5D).translate(laserOutputSide, 0.5D); }