Files
Purpur/patches/server/0190-Add-toggle-for-sand-duping-fix.patch
BillyGalbreath 36cc6584f3 Updated Upstream (Paper)
Upstream has released updates that appear to apply and compile correctly

Paper Changes:
PaperMC/Paper@aab1f8a Fix swamp hut cat generation deadlock
PaperMC/Paper@dc96bba Ensure the item sent isn't air (#7584)
PaperMC/Paper@bfa33d9 Various improvements to console color formatting (#7560)
PaperMC/Paper@87927e1 Fix CreativeCategory API (#7586)
PaperMC/Paper@ab03538 Fix colors in some console messages
PaperMC/Paper@1358d1e Updated Upstream (CraftBukkit/Spigot) (#7580)
2022-03-13 14:24:00 -05:00

45 lines
2.1 KiB
Diff

From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
From: William Blake Galbreath <Blake.Galbreath@GMail.com>
Date: Fri, 4 Jun 2021 09:13:54 -0500
Subject: [PATCH] Add toggle for sand duping fix
diff --git a/src/main/java/net/minecraft/world/entity/item/FallingBlockEntity.java b/src/main/java/net/minecraft/world/entity/item/FallingBlockEntity.java
index e234373432f34f237f884f7054c0d80829228522..22916618d5b5096802410a174c9a593d6a3a1121 100644
--- a/src/main/java/net/minecraft/world/entity/item/FallingBlockEntity.java
+++ b/src/main/java/net/minecraft/world/entity/item/FallingBlockEntity.java
@@ -121,7 +121,7 @@ public class FallingBlockEntity extends Entity {
@Override
public void tick() {
// Paper start - fix sand duping
- if (this.isRemoved()) {
+ if (this.level.purpurConfig.fixSandDuping && this.isRemoved()) { // Purpur
return;
}
// Paper end - fix sand duping
@@ -138,7 +138,7 @@ public class FallingBlockEntity extends Entity {
this.move(MoverType.SELF, this.getDeltaMovement());
// Paper start - fix sand duping
- if (this.isRemoved()) {
+ if (this.level.purpurConfig.fixSandDuping && this.isRemoved()) { // Purpur
return;
}
// Paper end - fix sand duping
diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
index 42db30881bda2917783e14210df3f74c72f12193..1f864bdc1e6d8cc389c0c9bccafb9ef596ce366a 100644
--- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
+++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
@@ -679,6 +679,11 @@ public class PurpurWorldConfig {
}
}
+ public boolean fixSandDuping = true;
+ private void sandSettings() {
+ fixSandDuping = getBoolean("blocks.sand.fix-duping", fixSandDuping);
+ }
+
public boolean shulkerBoxAllowOversizedStacks = false;
private void shulkerBoxSettings() {
shulkerBoxAllowOversizedStacks = getBoolean("blocks.shulker_box.allow-oversized-stacks", shulkerBoxAllowOversizedStacks);