diff --git a/src/main/java/com/simibubi/create/content/kinetics/deployer/DeployerMovementBehaviour.java b/src/main/java/com/simibubi/create/content/kinetics/deployer/DeployerMovementBehaviour.java index 8e5c17140..9c9761b32 100644 --- a/src/main/java/com/simibubi/create/content/kinetics/deployer/DeployerMovementBehaviour.java +++ b/src/main/java/com/simibubi/create/content/kinetics/deployer/DeployerMovementBehaviour.java @@ -73,6 +73,7 @@ public class DeployerMovementBehaviour implements MovementBehaviour { return; activate(context, pos, player, mode); + checkForPlacementAdvancement(); tryDisposeOfExcess(context); context.stall = player.blockBreakingProgress != null; } @@ -81,8 +82,10 @@ public class DeployerMovementBehaviour implements MovementBehaviour { Level world = context.world; FilterItemStack filter = context.getFilterFromBE(); - if (AllItems.SCHEMATIC.isIn(filter.item())) + if (AllItems.SCHEMATIC.isIn(filter.item())) { activateAsSchematicPrinter(context, pos, player, world, filter.item()); + return; + } Vec3 facingVec = Vec3.atLowerCornerOf(context.state.getValue(DeployerBlock.FACING) .getNormal()); @@ -104,7 +107,9 @@ public class DeployerMovementBehaviour implements MovementBehaviour { player.placedTracks = false; DeployerHandler.activate(player, vec, pos, facingVec, mode); + } + protected void checkForPlacementAdvancement() { if ((context.contraption instanceof MountedContraption || context.contraption instanceof CarriageContraption) && player.placedTracks && context.blockEntityData != null && context.blockEntityData.contains("Owner")) AllAdvancements.SELF_DEPLOYING.awardTo(world.getPlayerByUUID(context.blockEntityData.getUUID("Owner")));