From 25b4e4d5bef6ab60bb87bead602a59c64e2f6b5e Mon Sep 17 00:00:00 2001 From: JozsefA Date: Sat, 6 Mar 2021 14:33:01 -0800 Subject: [PATCH] The bell tolls for this bug. - Fix MovementBehavior#onSpeedChanged not ever being called. --- .../structureMovement/AbstractContraptionEntity.java | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/main/java/com/simibubi/create/content/contraptions/components/structureMovement/AbstractContraptionEntity.java b/src/main/java/com/simibubi/create/content/contraptions/components/structureMovement/AbstractContraptionEntity.java index 5b8c56e0b..3a9bd106d 100644 --- a/src/main/java/com/simibubi/create/content/contraptions/components/structureMovement/AbstractContraptionEntity.java +++ b/src/main/java/com/simibubi/create/content/contraptions/components/structureMovement/AbstractContraptionEntity.java @@ -253,6 +253,7 @@ public abstract class AbstractContraptionEntity extends Entity implements IEntit BlockInfo blockInfo = pair.left; MovementBehaviour actor = AllMovementBehaviours.of(blockInfo.state); + Vec3d oldMotion = context.motion; Vec3d actorPosition = toGlobalVector(VecHelper.getCenterOf(blockInfo.pos) .add(actor.getActiveAreaOffset(context)), 1); BlockPos gridPosition = new BlockPos(actorPosition); @@ -261,8 +262,6 @@ public abstract class AbstractContraptionEntity extends Entity implements IEntit context.rotation = v -> applyRotation(v, 1); context.position = actorPosition; - - Vec3d oldMotion = context.motion; if (!actor.isActive(context)) continue; if (newPosVisited && !context.stall) {