Add API methods to control if armor stands can move

This commit is contained in:
Riley Park
2016-12-21 11:47:25 -06:00
parent c28a11a1d8
commit e27e53d201
2 changed files with 56 additions and 22 deletions

View File

@@ -222,4 +222,15 @@ public class CraftArmorStand extends CraftLivingEntity implements ArmorStand {
public boolean hasEquipmentLock(EquipmentSlot equipmentSlot, LockType lockType) {
return (this.getHandle().disabledSlots & (1 << CraftEquipmentSlot.getNMS(equipmentSlot).getFilterBit(lockType.ordinal() * 8))) != 0;
}
// Paper start
@Override
public boolean canMove() {
return getHandle().canMove;
}
@Override
public void setCanMove(boolean move) {
getHandle().canMove = move;
}
// Paper end
}