mirror of
https://github.com/PurpurMC/Purpur.git
synced 2026-02-20 09:57:43 +01:00
prepare for 1.21.4 update
This commit is contained in:
@@ -1,55 +0,0 @@
|
||||
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
||||
From: William Blake Galbreath <blake.galbreath@gmail.com>
|
||||
Date: Sun, 6 Oct 2019 12:46:35 -0500
|
||||
Subject: [PATCH] Add option to set armorstand step height
|
||||
|
||||
|
||||
diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java
|
||||
index 163af180a12bf2847d6eab87e1fa77aef7cd3550..1057497963a615ae1aaafa5aac1f53471a00c763 100644
|
||||
--- a/src/main/java/net/minecraft/world/entity/Entity.java
|
||||
+++ b/src/main/java/net/minecraft/world/entity/Entity.java
|
||||
@@ -300,6 +300,7 @@ public abstract class Entity implements SyncedDataHolder, Nameable, EntityAccess
|
||||
public double xOld;
|
||||
public double yOld;
|
||||
public double zOld;
|
||||
+ public float maxUpStep; // Purpur
|
||||
public boolean noPhysics;
|
||||
private boolean wasOnFire;
|
||||
public final RandomSource random;
|
||||
@@ -5142,7 +5143,7 @@ public abstract class Entity implements SyncedDataHolder, Nameable, EntityAccess
|
||||
}
|
||||
|
||||
public float maxUpStep() {
|
||||
- return 0.0F;
|
||||
+ return maxUpStep;
|
||||
}
|
||||
|
||||
public void onExplosionHit(@Nullable Entity entity) {}
|
||||
diff --git a/src/main/java/net/minecraft/world/entity/decoration/ArmorStand.java b/src/main/java/net/minecraft/world/entity/decoration/ArmorStand.java
|
||||
index 70b8023c3badc745f342d5b0ab54699e3923826a..edb0cd90e28016c44b0aaf5c9ed5d7bdbced5295 100644
|
||||
--- a/src/main/java/net/minecraft/world/entity/decoration/ArmorStand.java
|
||||
+++ b/src/main/java/net/minecraft/world/entity/decoration/ArmorStand.java
|
||||
@@ -681,6 +681,7 @@ public class ArmorStand extends LivingEntity {
|
||||
|
||||
@Override
|
||||
public void tick() {
|
||||
+ maxUpStep = level().purpurConfig.armorstandStepHeight;
|
||||
// Paper start - Allow ArmorStands not to tick
|
||||
if (!this.canTick) {
|
||||
if (this.noTickPoseDirty) {
|
||||
diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
|
||||
index dcc8e4880c1bfff1abdc1b542000d61e3378d4f1..149360f01139fa4b14e27e5b34fe3fe7682c7ffc 100644
|
||||
--- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
|
||||
+++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
|
||||
@@ -91,6 +91,11 @@ public class PurpurWorldConfig {
|
||||
return value.isEmpty() ? fallback : value;
|
||||
}
|
||||
|
||||
+ public float armorstandStepHeight = 0.0F;
|
||||
+ private void armorstandSettings() {
|
||||
+ armorstandStepHeight = (float) getDouble("gameplay-mechanics.armorstand.step-height", armorstandStepHeight);
|
||||
+ }
|
||||
+
|
||||
public boolean idleTimeoutKick = true;
|
||||
public boolean idleTimeoutTickNearbyEntities = true;
|
||||
public boolean idleTimeoutCountAsSleeping = false;
|
||||
Reference in New Issue
Block a user