diff --git a/Spigot-Server-Patches/Delay-Chunk-Unloads-based-on-Player-Movement.patch b/Spigot-Server-Patches/Delay-Chunk-Unloads-based-on-Player-Movement.patch index 888ced24c6..f48bd759b8 100644 --- a/Spigot-Server-Patches/Delay-Chunk-Unloads-based-on-Player-Movement.patch +++ b/Spigot-Server-Patches/Delay-Chunk-Unloads-based-on-Player-Movement.patch @@ -21,9 +21,10 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000 --- a/src/main/java/com/destroystokyo/paper/PaperWorldConfig.java +++ b/src/main/java/com/destroystokyo/paper/PaperWorldConfig.java @@ -0,0 +0,0 @@ public class PaperWorldConfig { - } + private void isHopperPushBased() { + isHopperPushBased = getBoolean("hopper.push-based", true); } - ++ + public long delayChunkUnloadsBy; + private void delayChunkUnloadsBy() { + delayChunkUnloadsBy = PaperConfig.getSeconds(getString("delay-chunk-unloads-by", "0s")); @@ -32,10 +33,7 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000 + delayChunkUnloadsBy *= 1000; + } + } -+ - public boolean isHopperPushBased; - private void isHopperPushBased() { - isHopperPushBased = getBoolean("hopper.push-based", true); + } diff --git a/src/main/java/net/minecraft/server/Chunk.java b/src/main/java/net/minecraft/server/Chunk.java index 0000000000000000000000000000000000000000..0000000000000000000000000000000000000000 100644 --- a/src/main/java/net/minecraft/server/Chunk.java diff --git a/Spigot-Server-Patches/Fix-FallingBlocks-being-stuck-on-fences.patch b/Spigot-Server-Patches/Fix-FallingBlocks-being-stuck-on-fences.patch index f38b02e18c..949fb8e139 100644 --- a/Spigot-Server-Patches/Fix-FallingBlocks-being-stuck-on-fences.patch +++ b/Spigot-Server-Patches/Fix-FallingBlocks-being-stuck-on-fences.patch @@ -10,6 +10,20 @@ resulted in them always thinking they would be on air. We now first check, if if we are already on the ground. if not, we check if the falling block is inside of the hitbox of the block at y - 1. +diff --git a/src/main/java/com/destroystokyo/paper/PaperWorldConfig.java b/src/main/java/com/destroystokyo/paper/PaperWorldConfig.java +index 0000000000000000000000000000000000000000..0000000000000000000000000000000000000000 100644 +--- a/src/main/java/com/destroystokyo/paper/PaperWorldConfig.java ++++ b/src/main/java/com/destroystokyo/paper/PaperWorldConfig.java +@@ -0,0 +0,0 @@ public class PaperWorldConfig { + log("Old Cannon Behaviors: This feature may not be working entirely properly at the moment"); + } + } ++ ++ public boolean altFallingBlockOnGround; ++ private void altFallingBlockOnGround() { ++ altFallingBlockOnGround = getBoolean("use-alternate-fallingblock-onGround-detection", false); ++ } + } diff --git a/src/main/java/net/minecraft/server/BlockFalling.java b/src/main/java/net/minecraft/server/BlockFalling.java index 0000000000000000000000000000000000000000..0000000000000000000000000000000000000000 100644 --- a/src/main/java/net/minecraft/server/BlockFalling.java @@ -49,7 +63,7 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000 + if (!isOnGround()) { this.onGround = false; - // return; // CraftBukkit -+ return; // Paper ++ if (this.world.paperConfig.altFallingBlockOnGround) return; // Paper } this.motX *= 0.699999988079071D; @@ -60,8 +74,10 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000 + // Paper start + private boolean isOnGround() { + BlockPosition where = new BlockPosition(this.locX, this.locY - 0.009999999776482582D, this.locZ); ++ boolean cannotMoveThrough = !BlockFalling.canMoveThrough(this.world.getType(where)); ++ if (!this.world.paperConfig.altFallingBlockOnGround) return cannotMoveThrough; + -+ if (!BlockFalling.canMoveThrough(this.world.getType(where))) { ++ if (cannotMoveThrough) { + return true; + } + diff --git a/Spigot-Server-Patches/Make-entities-look-for-hoppers.patch b/Spigot-Server-Patches/Make-entities-look-for-hoppers.patch index 1201f66821..7575336fca 100644 --- a/Spigot-Server-Patches/Make-entities-look-for-hoppers.patch +++ b/Spigot-Server-Patches/Make-entities-look-for-hoppers.patch @@ -82,8 +82,8 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000 --- a/src/main/java/com/destroystokyo/paper/PaperWorldConfig.java +++ b/src/main/java/com/destroystokyo/paper/PaperWorldConfig.java @@ -0,0 +0,0 @@ public class PaperWorldConfig { - log("Old Cannon Behaviors: This feature may not be working entirely properly at the moment"); - } + private void altFallingBlockOnGround() { + altFallingBlockOnGround = getBoolean("use-alternate-fallingblock-onGround-detection", false); } + + public boolean isHopperPushBased; diff --git a/Spigot-Server-Patches/Toggleable-Elytra-Wall-Damage.patch b/Spigot-Server-Patches/Toggleable-Elytra-Wall-Damage.patch index 2ec738396f..5e378a68aa 100644 --- a/Spigot-Server-Patches/Toggleable-Elytra-Wall-Damage.patch +++ b/Spigot-Server-Patches/Toggleable-Elytra-Wall-Damage.patch @@ -11,8 +11,8 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000 --- a/src/main/java/com/destroystokyo/paper/PaperWorldConfig.java +++ b/src/main/java/com/destroystokyo/paper/PaperWorldConfig.java @@ -0,0 +0,0 @@ public class PaperWorldConfig { - private void isHopperPushBased() { - isHopperPushBased = getBoolean("hopper.push-based", true); + delayChunkUnloadsBy *= 1000; + } } + + public boolean elytraHitWallDamage = true;