From d70770d296141d1b912506cb68afeba7b4162cee Mon Sep 17 00:00:00 2001 From: Thutmose Date: Thu, 3 Dec 2020 19:35:04 -0500 Subject: [PATCH] Update ControllerTile.java this should fix #11 --- .../tech/common/blocks/lift/ControllerTile.java | 15 ++++++++++----- 1 file changed, 10 insertions(+), 5 deletions(-) diff --git a/src/main/java/thut/tech/common/blocks/lift/ControllerTile.java b/src/main/java/thut/tech/common/blocks/lift/ControllerTile.java index b413844..33e934c 100644 --- a/src/main/java/thut/tech/common/blocks/lift/ControllerTile.java +++ b/src/main/java/thut/tech/common/blocks/lift/ControllerTile.java @@ -339,11 +339,8 @@ public void tick() if (this.here == null) this.here = Vector3.getNewVector(); this.here.set(this); EntityLift lift = this.getLift(); - // if (this.liftID != null) - // { - // System.out.println(lift + " " + this.liftID); - // System.out.println(this.floor); - // } + + // Processing beyond here is only server side! if (this.getWorld().isRemote) return; if (this.world instanceof IBlockEntityWorld) return; @@ -457,6 +454,14 @@ else if (this.lift == null) { this.lift = EntityLift.getLiftFromUUID(this.liftID, this.getWorld()); + // Client side process this differently for when the tile entity + // ticks before the lift actually loads in. + if (this.getWorld().isRemote) + { + if (this.lift != null) this.setLift(this.lift); + return this.lift; + } + if (this.lift == null) this.setLift(null); else {