diff options
author | maxcom1 <[email protected]> | 2024-03-23 22:26:17 +0100 |
---|---|---|
committer | GitHub <[email protected]> | 2024-03-23 17:26:17 -0400 |
commit | b6001403e9703cadaa6e8c8558e732b91c3c6d6e (patch) | |
tree | a8c57bbc334a8ad48d4ad2b43db335667b142bee /patches/server/0731-Fix-NBT-pieces-overriding-a-block-entity-during-worl.patch | |
parent | 9ec7dfcbc41c6e625de0050b6997160a75df9f44 (diff) | |
download | Paper-b6001403e9703cadaa6e8c8558e732b91c3c6d6e.tar.gz Paper-b6001403e9703cadaa6e8c8558e732b91c3c6d6e.zip |
Add methods to change entity physics (#10334)
Diffstat (limited to 'patches/server/0731-Fix-NBT-pieces-overriding-a-block-entity-during-worl.patch')
-rw-r--r-- | patches/server/0731-Fix-NBT-pieces-overriding-a-block-entity-during-worl.patch | 40 |
1 files changed, 0 insertions, 40 deletions
diff --git a/patches/server/0731-Fix-NBT-pieces-overriding-a-block-entity-during-worl.patch b/patches/server/0731-Fix-NBT-pieces-overriding-a-block-entity-during-worl.patch deleted file mode 100644 index aa5772fe8a..0000000000 --- a/patches/server/0731-Fix-NBT-pieces-overriding-a-block-entity-during-worl.patch +++ /dev/null @@ -1,40 +0,0 @@ -From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001 -From: etil2jz <[email protected]> -Date: Sat, 2 Apr 2022 23:29:24 +0200 -Subject: [PATCH] Fix NBT pieces overriding a block entity during worldgen - deadlock - -By checking if the world passed into StructureTemplate's placeInWorld -is not a WorldGenRegion, we can bypass the deadlock entirely. -See https://bugs.mojang.com/browse/MC-246262 - -diff --git a/src/main/java/net/minecraft/world/level/levelgen/structure/templatesystem/StructureTemplate.java b/src/main/java/net/minecraft/world/level/levelgen/structure/templatesystem/StructureTemplate.java -index be8aab51a1b92a3a0cc94976975fc3aabc46f0b4..ae8a42261337bf736d0cc1bbe18da2b773417ca4 100644 ---- a/src/main/java/net/minecraft/world/level/levelgen/structure/templatesystem/StructureTemplate.java -+++ b/src/main/java/net/minecraft/world/level/levelgen/structure/templatesystem/StructureTemplate.java -@@ -279,7 +279,11 @@ public class StructureTemplate { - - if (definedstructure_blockinfo.nbt != null) { - tileentity = world.getBlockEntity(blockposition2); -- Clearable.tryClear(tileentity); -+ // Paper start - Fix NBT pieces overriding a block entity during worldgen deadlock -+ if (!(world instanceof net.minecraft.world.level.WorldGenLevel)) { -+ Clearable.tryClear(tileentity); -+ } -+ // Paper end - Fix NBT pieces overriding a block entity during worldgen deadlock - world.setBlock(blockposition2, Blocks.BARRIER.defaultBlockState(), 20); - } - // CraftBukkit start -@@ -406,7 +410,11 @@ public class StructureTemplate { - if (pair1.getSecond() != null) { - tileentity = world.getBlockEntity(blockposition6); - if (tileentity != null) { -- tileentity.setChanged(); -+ // Paper start - Fix NBT pieces overriding a block entity during worldgen deadlock -+ if (!(world instanceof net.minecraft.world.level.WorldGenLevel)) { -+ tileentity.setChanged(); -+ } -+ // Paper end - Fix NBT pieces overriding a block entity during worldgen deadlock - } - } - } |