2022-06-07 21:55:39 +02:00
|
|
|
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
|
|
|
From: Aikar <aikar@aikar.co>
|
|
|
|
Date: Sun, 3 Apr 2016 17:48:50 -0400
|
|
|
|
Subject: [PATCH] Fix Cancelling BlockPlaceEvent triggering physics
|
|
|
|
|
|
|
|
|
|
|
|
diff --git a/src/main/java/net/minecraft/server/level/ServerLevel.java b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
2024-10-25 21:24:15 +02:00
|
|
|
index 6ec83b72bb9f762d606fcbf4b93c70f2b025f48f..5a9c703a252d0c1c57c23ef021e57cdd1de31585 100644
|
2022-06-07 21:55:39 +02:00
|
|
|
--- a/src/main/java/net/minecraft/server/level/ServerLevel.java
|
|
|
|
+++ b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
2024-10-22 20:04:31 +02:00
|
|
|
@@ -1402,11 +1402,13 @@ public class ServerLevel extends Level implements ServerEntityGetter, WorldGenLe
|
2022-06-07 21:55:39 +02:00
|
|
|
|
|
|
|
@Override
|
2024-10-22 20:04:31 +02:00
|
|
|
public void updateNeighborsAt(BlockPos pos, Block block) {
|
2022-06-07 21:55:39 +02:00
|
|
|
+ if (captureBlockStates) { return; } // Paper - Cancel all physics during placement
|
2024-10-22 20:04:31 +02:00
|
|
|
this.updateNeighborsAt(pos, block, ExperimentalRedstoneUtils.initialOrientation(this, (Direction) null, (Direction) null));
|
|
|
|
}
|
|
|
|
|
|
|
|
@Override
|
|
|
|
public void updateNeighborsAt(BlockPos pos, Block sourceBlock, @Nullable Orientation orientation) {
|
|
|
|
+ if (captureBlockStates) { return; } // Paper - Cancel all physics during placement
|
|
|
|
this.neighborUpdater.updateNeighborsAtExceptFromFacing(pos, sourceBlock, (Direction) null, orientation);
|
2022-06-07 21:55:39 +02:00
|
|
|
}
|
|
|
|
|