9
0
mirror of https://github.com/Samsuik/Sakura.git synced 2025-12-28 03:09:07 +00:00

Add carpet to fluids-break-redstone (#20)

* Create 0075-Configure-fluids-breaking-wool-carpet.patch

* rebase

* use instanceof instead of blocktags

---------

Co-authored-by: Samsuik <kfian294ma4@gmail.com>
This commit is contained in:
Max Renner
2024-08-10 10:27:30 -04:00
committed by GitHub
parent 2fb979a69e
commit b4d782565b

View File

@@ -5,7 +5,7 @@ Subject: [PATCH] Configure fluids breaking redstone
diff --git a/src/main/java/net/minecraft/world/level/material/FlowingFluid.java b/src/main/java/net/minecraft/world/level/material/FlowingFluid.java
index 700226cc972693336987184c761c0c8808fd77ad..626b3c04547ca253b254604c8bf5fa004eed806a 100644
index 700226cc972693336987184c761c0c8808fd77ad..b0d1c86dbbe6b6f1b8ac8f531b5f3bc3669e232a 100644
--- a/src/main/java/net/minecraft/world/level/material/FlowingFluid.java
+++ b/src/main/java/net/minecraft/world/level/material/FlowingFluid.java
@@ -466,6 +466,10 @@ public abstract class FlowingFluid extends Fluid {
@@ -13,7 +13,7 @@ index 700226cc972693336987184c761c0c8808fd77ad..626b3c04547ca253b254604c8bf5fa00
if (block instanceof LiquidBlockContainer ifluidcontainer) {
return ifluidcontainer.canPlaceLiquid((Player) null, world, pos, state, fluid);
+ // Sakura start
+ } else if (world instanceof Level level && !level.sakuraConfig().technical.redstone.fluidsBreakRedstone && state.isSignalSource()) {
+ } else if (world instanceof Level level && !level.sakuraConfig().technical.redstone.fluidsBreakRedstone && (state.isSignalSource() || state.getBlock() instanceof net.minecraft.world.level.block.CarpetBlock)) {
+ return false;
+ // Sakura end
} else {