mirror of
https://github.com/PurpurMC/Purpur.git
synced 2026-02-19 01:17:42 +01:00
Updated Upstream (Paper & Pufferfish)
Upstream has released updates that appear to apply and compile correctly Paper Changes: PaperMC/Paper@2ec04e0 Use correct headerLocation for regionfile initialisation PaperMC/Paper@f23c039 Fix infinite recursion in spawnCategoryForChunk/Position PaperMC/Paper@9940bca API for creating command sender which forwards feedback (#7432) Pufferfish Changes: pufferfish-gg/Pufferfish@d549dda Improve vanilla parity of suffocation patch pufferfish-gg/Pufferfish@17b3430 Updated Upstream (Paper) pufferfish-gg/Pufferfish@bcbaf3e Fix div by zero
This commit is contained in:
@@ -617,10 +617,10 @@ index 0000000000000000000000000000000000000000..020368da69b9a492155f6de6297f7473
|
||||
+}
|
||||
diff --git a/src/main/java/gg/pufferfish/pufferfish/PufferfishConfig.java b/src/main/java/gg/pufferfish/pufferfish/PufferfishConfig.java
|
||||
new file mode 100644
|
||||
index 0000000000000000000000000000000000000000..284f9eb542b686833ec54d4de6493d7dac5aa6b8
|
||||
index 0000000000000000000000000000000000000000..889561a6b0cb46405398d94fa071d33d3f02c3df
|
||||
--- /dev/null
|
||||
+++ b/src/main/java/gg/pufferfish/pufferfish/PufferfishConfig.java
|
||||
@@ -0,0 +1,266 @@
|
||||
@@ -0,0 +1,275 @@
|
||||
+package gg.pufferfish.pufferfish;
|
||||
+
|
||||
+import java.io.File;
|
||||
@@ -789,6 +789,15 @@ index 0000000000000000000000000000000000000000..284f9eb542b686833ec54d4de6493d7d
|
||||
+ "This can be overridden per-player with the permission pufferfish.usebooks");
|
||||
+ }
|
||||
+
|
||||
+ public static boolean enableSuffocationOptimization;
|
||||
+ private static void suffocationOptimization() {
|
||||
+ enableSuffocationOptimization = getBoolean("enable-suffocation-optimization", true,
|
||||
+ "Optimizes the suffocation check by selectively skipping",
|
||||
+ "the check in a way that still appears vanilla. This should",
|
||||
+ "be left enabled on most servers, but is provided as a",
|
||||
+ "configuration option if the vanilla deviation is undesirable.");
|
||||
+ }
|
||||
+
|
||||
+ public static boolean enableAsyncMobSpawning;
|
||||
+ public static boolean asyncMobSpawningInitialized;
|
||||
+ private static void asyncMobSpawning() {
|
||||
@@ -2728,7 +2737,7 @@ index 419a7e9614af2328ed401fc954196056243a984c..9bc568a2b0df13f55ee8670839b9e6a6
|
||||
public final String id;
|
||||
|
||||
diff --git a/src/main/java/net/minecraft/world/entity/LivingEntity.java b/src/main/java/net/minecraft/world/entity/LivingEntity.java
|
||||
index 25338fe4cfdc683ca4c01487e166a1649c6f640b..a6681690e1e556440320c492bf2a8e617008baa1 100644
|
||||
index 25338fe4cfdc683ca4c01487e166a1649c6f640b..3236a1dc51c394b784d3f42b78e76bf7c2f69c37 100644
|
||||
--- a/src/main/java/net/minecraft/world/entity/LivingEntity.java
|
||||
+++ b/src/main/java/net/minecraft/world/entity/LivingEntity.java
|
||||
@@ -139,7 +139,6 @@ import org.bukkit.event.entity.EntityTeleportEvent;
|
||||
@@ -2745,7 +2754,7 @@ index 25338fe4cfdc683ca4c01487e166a1649c6f640b..a6681690e1e556440320c492bf2a8e61
|
||||
boolean flag = this instanceof net.minecraft.world.entity.player.Player;
|
||||
-
|
||||
- if (this.isInWall()) {
|
||||
+ if (tickCount % 20 == 0 && couldPossiblyBeHurt(1.0F) && this.isInWall()) { // Pufferfish - optimize suffocation
|
||||
+ if ((!gg.pufferfish.pufferfish.PufferfishConfig.enableSuffocationOptimization || (tickCount % 10 == 0 && couldPossiblyBeHurt(1.0F))) && this.isInWall()) { // Pufferfish - optimize suffocation
|
||||
this.hurt(DamageSource.IN_WALL, 1.0F);
|
||||
} else if (flag && !this.level.getWorldBorder().isWithinBounds(this.getBoundingBox())) {
|
||||
double d0 = this.level.getWorldBorder().getDistanceToBorder(this) + this.level.getWorldBorder().getDamageSafeZone();
|
||||
@@ -3526,7 +3535,7 @@ index 89bc9f452556bafdcd8b76668639ee33c383596e..a98d115b7dccd836fa2c0f50333730db
|
||||
}
|
||||
|
||||
diff --git a/src/main/java/net/minecraft/world/level/NaturalSpawner.java b/src/main/java/net/minecraft/world/level/NaturalSpawner.java
|
||||
index c6bddf5e08376f1f254a27fc38647587eefcb00a..4ae9717b9ee77b3c28282e6560fc42081b6188ae 100644
|
||||
index 29b27f31080204c9cf33c9eeb8f48bf7928e0371..656b7e07ce6294f4b56b99b928cf37da41ea167d 100644
|
||||
--- a/src/main/java/net/minecraft/world/level/NaturalSpawner.java
|
||||
+++ b/src/main/java/net/minecraft/world/level/NaturalSpawner.java
|
||||
@@ -431,12 +431,12 @@ public final class NaturalSpawner {
|
||||
@@ -4099,7 +4108,7 @@ index e387de8adc480eac27b58b6f3f0d331ffc4382f1..6dba9d6bb7b81fe176cc0fabbb60b554
|
||||
|
||||
@Nullable
|
||||
diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java
|
||||
index 54e8f0f367645f3aa8af5b1cb69c39c0cec9381f..868e148e6a8cd85ef89b79ad539dd5f3bce0a7c7 100644
|
||||
index 1a1f5c8f9a049d65043f12374fe694068f7d08cf..4bfae47b8163d2737ba796827be8557166db84d1 100644
|
||||
--- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java
|
||||
+++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java
|
||||
@@ -254,7 +254,7 @@ import javax.annotation.Nullable; // Paper
|
||||
|
||||
Reference in New Issue
Block a user