Armed and unprepared

- Fixed Mechanical Arms losing their configuration when placed in survival mode
This commit is contained in:
simibubi 2022-08-24 10:42:43 +02:00
parent d90682e7c3
commit a027f82252
3 changed files with 7 additions and 4 deletions

View file

@ -86,9 +86,6 @@ public class EjectorTargetHandler {
}
public static void flushSettings(BlockPos pos) {
if (currentItem == null)
return;
int h = 0;
int v = 0;

View file

@ -89,7 +89,7 @@ public class ArmInteractionPointHandler {
}
public static void flushSettings(BlockPos pos) {
if (currentItem == null)
if (currentSelection == null)
return;
int removed = 0;

View file

@ -66,6 +66,7 @@ public class ArmTileEntity extends KineticTileEntity implements ITransformableTE
LerpedFloat clawAngle;
float previousBaseAngle;
boolean updateInteractionPoints;
int tooltipWarmup;
//
protected ScrollOptionBehaviour<SelectionMode> selectionMode;
@ -97,6 +98,7 @@ public class ArmTileEntity extends KineticTileEntity implements ITransformableTE
previousBaseAngle = previousTarget.baseAngle;
updateInteractionPoints = true;
redstoneLocked = false;
tooltipWarmup = 15;
}
@Override
@ -118,6 +120,8 @@ public class ArmTileEntity extends KineticTileEntity implements ITransformableTE
initInteractionPoints();
boolean targetReached = tickMovementProgress();
if (tooltipWarmup > 0)
tooltipWarmup--;
if (chasedPointProgress < 1) {
if (phase == Phase.MOVE_TO_INPUT) {
ArmInteractionPoint point = getTargetedInteractionPoint();
@ -561,6 +565,8 @@ public class ArmTileEntity extends KineticTileEntity implements ITransformableTE
return true;
if (isPlayerSneaking)
return false;
if (tooltipWarmup > 0)
return false;
if (!inputs.isEmpty())
return false;
if (!outputs.isEmpty())