Config to show Armor Stand arms on spawn

This commit is contained in:
Encode42
2025-01-11 17:35:04 -08:00
committed by granny
parent 620948c640
commit 434ace14d3
3 changed files with 4 additions and 39 deletions

View File

@@ -1,6 +1,6 @@
--- a/net/minecraft/world/entity/decoration/ArmorStand.java
+++ b/net/minecraft/world/entity/decoration/ArmorStand.java
@@ -93,10 +_,12 @@
@@ -93,10 +_,13 @@
private boolean noTickPoseDirty = false;
private boolean noTickEquipmentDirty = false;
// Paper end - Allow ArmorStands not to tick
@@ -10,6 +10,7 @@
super(entityType, level);
if (level != null) this.canTick = level.paperConfig().entities.armorStands.tick; // Paper - Allow ArmorStands not to tick
+ if (level != null) this.canMovementTick = level.purpurConfig.armorstandMovement; // Purpur - Movement options for armor stands
+ this.setShowArms(level != null && level.purpurConfig.armorstandPlaceWithArms); // Purpur - Config to show Armor Stand arms on spawn
}
public ArmorStand(Level level, double x, double y, double z) {

View File

@@ -95,6 +95,7 @@ public class PurpurWorldConfig {
public boolean armorstandMovement = true;
public boolean armorstandWaterMovement = true;
public boolean armorstandWaterFence = true;
public boolean armorstandPlaceWithArms = false;
private void armorstandSettings() {
armorstandStepHeight = (float) getDouble("gameplay-mechanics.armorstand.step-height", armorstandStepHeight);
armorstandSetNameVisible = getBoolean("gameplay-mechanics.armorstand.set-name-visible-when-placing-with-custom-name", armorstandSetNameVisible);
@@ -102,6 +103,7 @@ public class PurpurWorldConfig {
armorstandMovement = getBoolean("gameplay-mechanics.armorstand.can-movement-tick", armorstandMovement);
armorstandWaterMovement = getBoolean("gameplay-mechanics.armorstand.can-move-in-water", armorstandWaterMovement);
armorstandWaterFence = getBoolean("gameplay-mechanics.armorstand.can-move-in-water-over-fence", armorstandWaterFence);
armorstandPlaceWithArms = getBoolean("gameplay-mechanics.armorstand.place-with-arms-visible", armorstandPlaceWithArms);
}
public boolean arrowMovementResetsDespawnCounter = true;