diff --git a/PATCHES.md b/PATCHES.md index 46bed4da..2a3f8a83 100644 --- a/PATCHES.md +++ b/PATCHES.md @@ -227,6 +227,7 @@ # Patches | server | Fix advancement triggers on entity death | BillyGalbreath | | | server | Fix chunks refusing to unload at low TPS | Spottedleaf | | | server | Fix cow rotation when shearing mooshroom | William Blake Galbreath | | +| server | Fix dangerous end portal logic | Spottedleaf | | | server | Fix exp drop of zombie pigmen (MC-56653) | Phoenix616 | | | server | Fix incorrect isRealPlayer init | Spottedleaf | | | api | Fix javadoc warnings (missing @param and @return) | BillyGalbreath | | diff --git a/Paper b/Paper index 525d0e3d..b94a99b0 160000 --- a/Paper +++ b/Paper @@ -1 +1 @@ -Subproject commit 525d0e3d3752fa78e7c136a4d4bf13c3278691d9 +Subproject commit b94a99b0337823efb2863243deeb8701c3ff781e diff --git a/patches/Airplane/patches/server/0002-Airplane-Branding-Changes.patch b/patches/Airplane/patches/server/0002-Airplane-Branding-Changes.patch index 043787f5..7ac92088 100644 --- a/patches/Airplane/patches/server/0002-Airplane-Branding-Changes.patch +++ b/patches/Airplane/patches/server/0002-Airplane-Branding-Changes.patch @@ -72,7 +72,7 @@ index d50b61876f15d95b836b3dd81d9c3492c91a8448..5460f57f0473868b3fb09c526a1767f7 return history != null ? TextComponent.ofChildren(updateMessage, Component.newline(), history) : updateMessage; diff --git a/src/main/java/net/minecraft/server/MinecraftServer.java b/src/main/java/net/minecraft/server/MinecraftServer.java -index 264ed751002b3f52294d00d3135503dabc639a13..b2ae9d92dd2c93304a282b08099dfb1acd72ef4f 100644 +index 6f90a4182e008b49a4b3328e569311382e4bec0d..f9aa12422fd44e0d00c3f4e4e0116e0148d3acea 100644 --- a/src/main/java/net/minecraft/server/MinecraftServer.java +++ b/src/main/java/net/minecraft/server/MinecraftServer.java @@ -1650,7 +1650,7 @@ public abstract class MinecraftServer extends IAsyncTaskHandlerReentrant 300) { diff --git a/src/main/java/net/minecraft/world/entity/monster/piglin/EntityPiglin.java b/src/main/java/net/minecraft/world/entity/monster/piglin/EntityPiglin.java -index 9a7bebd77302dbfd07ac802acbe2b9cb80eec26f..4ee979a2771b1c97379a77af34b9e7b6de34d67b 100644 +index 9a7bebd77302dbfd07ac802acbe2b9cb80eec26f..99cdcc9a9a7e6227a165c4ef779f8e76a99ec56a 100644 --- a/src/main/java/net/minecraft/world/entity/monster/piglin/EntityPiglin.java +++ b/src/main/java/net/minecraft/world/entity/monster/piglin/EntityPiglin.java -@@ -272,12 +272,16 @@ public class EntityPiglin extends EntityPiglinAbstract implements ICrossbow { +@@ -272,12 +272,17 @@ public class EntityPiglin extends EntityPiglinAbstract implements ICrossbow { return !this.cannotHunt; } @@ -171,12 +171,13 @@ index 9a7bebd77302dbfd07ac802acbe2b9cb80eec26f..4ee979a2771b1c97379a77af34b9e7b6 this.getBehaviorController().a((WorldServer) this.world, (EntityPiglin) this); // CraftBukkit - decompile error this.world.getMethodProfiler().exit(); PiglinAI.b(this); -+ } // Airplane end ++ } ++ // Airplane end super.mobTick(); } diff --git a/src/main/java/net/minecraft/world/entity/npc/EntityVillager.java b/src/main/java/net/minecraft/world/entity/npc/EntityVillager.java -index 9278b8546a57f21051a65d59c2c01d39afaa68cc..61eaa3e8f961a30e2dc9ae8701ba3b875176e7e0 100644 +index c29f05b6fd0664345d8d09f898777a3e44f866c4..75c3239c9869863d9653916f3656c882b798cf07 100644 --- a/src/main/java/net/minecraft/world/entity/npc/EntityVillager.java +++ b/src/main/java/net/minecraft/world/entity/npc/EntityVillager.java @@ -231,11 +231,17 @@ public class EntityVillager extends EntityVillagerAbstract implements Reputation diff --git a/patches/Airplane/patches/server/0022-More-debug-for-plugins-not-shutting-down-tasks.patch b/patches/Airplane/patches/server/0022-More-debug-for-plugins-not-shutting-down-tasks.patch index b70a06ab..6a444458 100644 --- a/patches/Airplane/patches/server/0022-More-debug-for-plugins-not-shutting-down-tasks.patch +++ b/patches/Airplane/patches/server/0022-More-debug-for-plugins-not-shutting-down-tasks.patch @@ -5,10 +5,10 @@ Subject: [PATCH] More debug for plugins not shutting down tasks diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -index 4d0a9c89ca6838907b25ac4b2b1a849844efa7ec..e476806646c89c22da7e733d8072e0073383bd79 100644 +index d8697db30801606d46936caea2a5a41f82a34082..eab5bd32860d136864ca8f74be264236cf530910 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -@@ -995,6 +995,11 @@ public final class CraftServer implements Server { +@@ -994,6 +994,11 @@ public final class CraftServer implements Server { plugin.getDescription().getName(), "This plugin is not properly shutting down its async tasks when it is being shut down. This task may throw errors during the final shutdown logs and might not complete before process dies." )); diff --git a/patches/Airplane/patches/server/0025-Skip-creating-hashset-for-entity-track-range.patch b/patches/Airplane/patches/server/0025-Skip-creating-hashset-for-entity-track-range.patch index 1004c33e..fc5f4527 100644 --- a/patches/Airplane/patches/server/0025-Skip-creating-hashset-for-entity-track-range.patch +++ b/patches/Airplane/patches/server/0025-Skip-creating-hashset-for-entity-track-range.patch @@ -5,7 +5,7 @@ Subject: [PATCH] Skip creating hashset for entity track range diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java -index ebcb668b7f793d9c19bb098ff54007280c6d07d8..2a779f1219de2eb1d2ba7d28110bed4824b1d5c5 100644 +index 21f8e6b6dd123675d59cca20935d7048f6c98b23..1ea76604a375b60aa2b93af6c562151030907b1c 100644 --- a/src/main/java/net/minecraft/world/entity/Entity.java +++ b/src/main/java/net/minecraft/world/entity/Entity.java @@ -319,10 +319,39 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, ne diff --git a/patches/Airplane/patches/server/0027-Reduce-frequency-of-checking-for-entity-despawn.patch b/patches/Airplane/patches/server/0027-Reduce-frequency-of-checking-for-entity-despawn.patch index 3a94d330..751f2d7f 100644 --- a/patches/Airplane/patches/server/0027-Reduce-frequency-of-checking-for-entity-despawn.patch +++ b/patches/Airplane/patches/server/0027-Reduce-frequency-of-checking-for-entity-despawn.patch @@ -26,7 +26,7 @@ index 7ec84ef1d1cbb1fabf4c590a2f2c1da3cc181010..c9e00334655ccd273ba108a541ed1cb0 + } diff --git a/src/main/java/net/minecraft/world/entity/EntityInsentient.java b/src/main/java/net/minecraft/world/entity/EntityInsentient.java -index d325b2437887afad634d569e8c6483a14d3b967c..91eecf296905b85d7cc602dbc3a7b14479ec686a 100644 +index 7582b91a24253473b2770d4e1bf053446238643c..892bfadbb1e7d09996df61aaee2cab74187f73d0 100644 --- a/src/main/java/net/minecraft/world/entity/EntityInsentient.java +++ b/src/main/java/net/minecraft/world/entity/EntityInsentient.java @@ -774,8 +774,15 @@ public abstract class EntityInsentient extends EntityLiving { diff --git a/patches/Airplane/patches/server/0029-Config-to-disable-method-profiler.patch b/patches/Airplane/patches/server/0029-Config-to-disable-method-profiler.patch index cc9f5a86..e6c48758 100644 --- a/patches/Airplane/patches/server/0029-Config-to-disable-method-profiler.patch +++ b/patches/Airplane/patches/server/0029-Config-to-disable-method-profiler.patch @@ -23,7 +23,7 @@ index c9e00334655ccd273ba108a541ed1cb0633f69b7..65adf3ceda012c8cfdea675c40e2bb27 + } diff --git a/src/main/java/net/minecraft/server/MinecraftServer.java b/src/main/java/net/minecraft/server/MinecraftServer.java -index b2ae9d92dd2c93304a282b08099dfb1acd72ef4f..baa6698a2444edc1e9a264eeb8771df47e956849 100644 +index f9aa12422fd44e0d00c3f4e4e0116e0148d3acea..26f423d3fdc958764758573043310f84da08a08e 100644 --- a/src/main/java/net/minecraft/server/MinecraftServer.java +++ b/src/main/java/net/minecraft/server/MinecraftServer.java @@ -2200,7 +2200,11 @@ public abstract class MinecraftServer extends IAsyncTaskHandlerReentrant= this.left.getSize() ? this.right.splitStack(i - this.left.getSize(), j) : this.left.splitStack(i, j); diff --git a/src/main/java/net/minecraft/world/level/block/entity/TileEntityChest.java b/src/main/java/net/minecraft/world/level/block/entity/TileEntityChest.java -index 111f62d0e5b40e945793b8f504f2c035c0884a6a..cfabc9047cd3e972af84700725355d0fe149b221 100644 +index 111f62d0e5b40e945793b8f504f2c035c0884a6a..324b752c70e0bd7ea06caa98ec15cdd4e6ea40ae 100644 --- a/src/main/java/net/minecraft/world/level/block/entity/TileEntityChest.java +++ b/src/main/java/net/minecraft/world/level/block/entity/TileEntityChest.java @@ -36,7 +36,7 @@ import org.bukkit.entity.HumanEntity; @@ -281,8 +281,12 @@ index 111f62d0e5b40e945793b8f504f2c035c0884a6a..cfabc9047cd3e972af84700725355d0f protected float a; protected float b; public int viewingCount; -@@ -75,9 +75,31 @@ public class TileEntityChest extends TileEntityLootable { // Paper - Remove ITic +@@ -73,10 +73,34 @@ public class TileEntityChest extends TileEntityLootable { // Paper - Remove ITic + } + // CraftBukkit end ++ private final boolean isNative = getClass().equals(TileEntityChest.class); // Airplane ++ protected TileEntityChest(TileEntityTypes tileentitytypes) { super(tileentitytypes); + // Airplane start @@ -291,29 +295,28 @@ index 111f62d0e5b40e945793b8f504f2c035c0884a6a..cfabc9047cd3e972af84700725355d0f + */ + this.items = new gg.airplane.structs.ItemListWithBitset(27); + // Airplane end - } - ++ } ++ + // Airplane start + @Override + public boolean hasEmptySlot(EnumDirection enumdirection) { -+ return !this.items.hasFullStacks(); ++ return isNative ? !this.items.hasFullStacks() : super.hasEmptySlot(enumdirection); + } + + @Override + public boolean isCompletelyFull(EnumDirection enumdirection) { -+ return this.items.hasFullStacks() && super.isCompletelyFull(enumdirection); ++ return isNative ? this.items.hasFullStacks() && super.isCompletelyFull(enumdirection) : super.isCompletelyFull(enumdirection); + } + + @Override + public boolean isCompletelyEmpty(EnumDirection enumdirection) { -+ return this.items.isCompletelyEmpty() || super.isCompletelyEmpty(enumdirection); -+ } ++ return isNative && this.items.isCompletelyEmpty() || super.isCompletelyEmpty(enumdirection); + } + // Airplane end -+ + public TileEntityChest() { this(TileEntityTypes.CHEST); - } -@@ -95,7 +117,7 @@ public class TileEntityChest extends TileEntityLootable { // Paper - Remove ITic +@@ -95,7 +119,7 @@ public class TileEntityChest extends TileEntityLootable { // Paper - Remove ITic @Override public void load(IBlockData iblockdata, NBTTagCompound nbttagcompound) { super.load(iblockdata, nbttagcompound); @@ -322,7 +325,7 @@ index 111f62d0e5b40e945793b8f504f2c035c0884a6a..cfabc9047cd3e972af84700725355d0f if (!this.b(nbttagcompound)) { ContainerUtil.b(nbttagcompound, this.items); } -@@ -295,7 +317,7 @@ public class TileEntityChest extends TileEntityLootable { // Paper - Remove ITic +@@ -295,7 +319,7 @@ public class TileEntityChest extends TileEntityLootable { // Paper - Remove ITic @Override protected void a(NonNullList nonnulllist) { diff --git a/patches/Akarin/patches/server/0001-Disable-the-Snooper.patch b/patches/Akarin/patches/server/0001-Disable-the-Snooper.patch index 33a14443..7b5fcb33 100644 --- a/patches/Akarin/patches/server/0001-Disable-the-Snooper.patch +++ b/patches/Akarin/patches/server/0001-Disable-the-Snooper.patch @@ -5,7 +5,7 @@ Subject: [PATCH] Disable the Snooper diff --git a/src/main/java/net/minecraft/server/MinecraftServer.java b/src/main/java/net/minecraft/server/MinecraftServer.java -index f9a5b96bf479c177f6a2f2a45258990c297ea3b8..3f33301c3349c1c04b869a001120d03697afae8d 100644 +index 6a561f0a6e076350b96212a1219a9658c4da6531..3e1e5e8b23a2d6a43deb37fafc0bdc7396f2a84a 100644 --- a/src/main/java/net/minecraft/server/MinecraftServer.java +++ b/src/main/java/net/minecraft/server/MinecraftServer.java @@ -1454,6 +1454,8 @@ public abstract class MinecraftServer extends IAsyncTaskHandlerReentrant a(GeneratorAccessSeed generatoraccessseed) { @@ -18,12 +18,6 @@ index dd623702131eaa1a65937a19a0e986e865322258..54ac8444702c3cfc2bcbaa6c8bc40398 long i = random.nextLong() & 65535L; return (List) WorldGenEnder.a.getUnchecked(i); - } - -+ public boolean generate(GeneratorAccessSeed generatoraccessseed, ChunkGenerator chunkgenerator, Random random, BlockPosition blockposition, WorldGenFeatureEndSpikeConfiguration worldgenfeatureendspikeconfiguration) { return a(generatoraccessseed, chunkgenerator, random, blockposition, worldgenfeatureendspikeconfiguration); } // Purpur - decompile error? - public boolean a(GeneratorAccessSeed generatoraccessseed, ChunkGenerator chunkgenerator, Random random, BlockPosition blockposition, WorldGenFeatureEndSpikeConfiguration worldgenfeatureendspikeconfiguration) { - List list = worldgenfeatureendspikeconfiguration.c(); - diff --git a/src/main/java/net/pl3x/purpur/PurpurConfig.java b/src/main/java/net/pl3x/purpur/PurpurConfig.java index 1a9d5409d38be0884c005524069c341a2dc27365..7a95f27827cbf5d5f69e0f3d55f327bac4203573 100644 --- a/src/main/java/net/pl3x/purpur/PurpurConfig.java diff --git a/patches/Purpur/patches/server/0089-Configurable-villager-breeding.patch b/patches/Purpur/patches/server/0089-Configurable-villager-breeding.patch index c0260ea2..a573d222 100644 --- a/patches/Purpur/patches/server/0089-Configurable-villager-breeding.patch +++ b/patches/Purpur/patches/server/0089-Configurable-villager-breeding.patch @@ -5,7 +5,7 @@ Subject: [PATCH] Configurable villager breeding diff --git a/src/main/java/net/minecraft/world/entity/npc/EntityVillager.java b/src/main/java/net/minecraft/world/entity/npc/EntityVillager.java -index 02fb339300669a2b3f702a67085dae3dae2f9908..9c187b015c9acd11a372ec4844bc6d5ead4ca73d 100644 +index bec501f1f9e8fcb4c2d6186b35912f9113a33f3a..fd25524e36317f69091150a85b5068fb6bcf189a 100644 --- a/src/main/java/net/minecraft/world/entity/npc/EntityVillager.java +++ b/src/main/java/net/minecraft/world/entity/npc/EntityVillager.java @@ -718,7 +718,7 @@ public class EntityVillager extends EntityVillagerAbstract implements Reputation diff --git a/patches/Purpur/patches/server/0100-Stop-squids-floating-on-top-of-water.patch b/patches/Purpur/patches/server/0100-Stop-squids-floating-on-top-of-water.patch index 7249293c..bdb96905 100644 --- a/patches/Purpur/patches/server/0100-Stop-squids-floating-on-top-of-water.patch +++ b/patches/Purpur/patches/server/0100-Stop-squids-floating-on-top-of-water.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Stop squids floating on top of water diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java -index 2f53f45e2e53ab01d67839957013da106b78ddc8..4e75650f95af5b1a0cb1f5052688d4f3eb0dce70 100644 +index aedfe9875780496e8404c3364eed0d0c920af538..0c98115022d5af56b41429b090048dd52243ca3f 100644 --- a/src/main/java/net/minecraft/world/entity/Entity.java +++ b/src/main/java/net/minecraft/world/entity/Entity.java -@@ -3587,8 +3587,13 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, ne +@@ -3620,8 +3620,13 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, ne this.lastYaw = this.yaw; } diff --git a/patches/Purpur/patches/server/0101-Ridables.patch b/patches/Purpur/patches/server/0101-Ridables.patch index b70ee9a4..61a1332b 100644 --- a/patches/Purpur/patches/server/0101-Ridables.patch +++ b/patches/Purpur/patches/server/0101-Ridables.patch @@ -5,7 +5,7 @@ Subject: [PATCH] Ridables diff --git a/src/main/java/net/minecraft/server/MinecraftServer.java b/src/main/java/net/minecraft/server/MinecraftServer.java -index 6fee6b5ea9e2a946bf170a8ad94ae785502419b0..6c0729b0b2a956607067885768cbe848d7406ad6 100644 +index 502675b7bef3322b88efff650b239bfedebc0785..45722de76788886efa664b1b4124903bf6870e7c 100644 --- a/src/main/java/net/minecraft/server/MinecraftServer.java +++ b/src/main/java/net/minecraft/server/MinecraftServer.java @@ -1544,6 +1544,7 @@ public abstract class MinecraftServer extends IAsyncTaskHandlerReentrant 0.0D; } @@ -203,7 +203,7 @@ index 4e75650f95af5b1a0cb1f5052688d4f3eb0dce70..668f613a901523e87780f33ffff565d9 public void a(float f, Vec3D vec3d) { Vec3D vec3d1 = a(vec3d, f, this.yaw); -@@ -2377,6 +2378,7 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, ne +@@ -2409,6 +2410,7 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, ne return this.a(entity, false); } @@ -211,7 +211,7 @@ index 4e75650f95af5b1a0cb1f5052688d4f3eb0dce70..668f613a901523e87780f33ffff565d9 public boolean a(Entity entity, boolean flag) { for (Entity entity1 = entity; entity1.vehicle != null; entity1 = entity1.vehicle) { if (entity1.vehicle == this) { -@@ -2472,6 +2474,13 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, ne +@@ -2504,6 +2506,13 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, ne this.passengers.add(entity); } @@ -225,7 +225,7 @@ index 4e75650f95af5b1a0cb1f5052688d4f3eb0dce70..668f613a901523e87780f33ffff565d9 } return true; // CraftBukkit } -@@ -2512,6 +2521,12 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, ne +@@ -2544,6 +2553,12 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, ne return false; } // Spigot end @@ -238,7 +238,7 @@ index 4e75650f95af5b1a0cb1f5052688d4f3eb0dce70..668f613a901523e87780f33ffff565d9 this.passengers.remove(entity); entity.j = 60; } -@@ -2677,6 +2692,7 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, ne +@@ -2710,6 +2725,7 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, ne this.setFlag(4, flag); } @@ -246,7 +246,7 @@ index 4e75650f95af5b1a0cb1f5052688d4f3eb0dce70..668f613a901523e87780f33ffff565d9 public boolean bE() { return this.glowing || this.world.isClientSide && this.getFlag(6); } -@@ -2899,6 +2915,7 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, ne +@@ -2932,6 +2948,7 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, ne public void setHeadRotation(float f) {} @@ -254,7 +254,7 @@ index 4e75650f95af5b1a0cb1f5052688d4f3eb0dce70..668f613a901523e87780f33ffff565d9 public void n(float f) {} public boolean bL() { -@@ -3340,6 +3357,18 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, ne +@@ -3373,6 +3390,18 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, ne return false; } @@ -273,7 +273,7 @@ index 4e75650f95af5b1a0cb1f5052688d4f3eb0dce70..668f613a901523e87780f33ffff565d9 @Override public void sendMessage(IChatBaseComponent ichatbasecomponent, UUID uuid) {} -@@ -3792,4 +3821,47 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, ne +@@ -3825,4 +3854,47 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, ne return ((ChunkProviderServer) world.getChunkProvider()).isInEntityTickingChunk(this); } // Paper end @@ -322,7 +322,7 @@ index 4e75650f95af5b1a0cb1f5052688d4f3eb0dce70..668f613a901523e87780f33ffff565d9 + // Purpur end } diff --git a/src/main/java/net/minecraft/world/entity/EntityInsentient.java b/src/main/java/net/minecraft/world/entity/EntityInsentient.java -index 698997425a7f5a7a5d46fa5d825ec26f61e6c7c4..dd1f4c4202e30a837b48b591327b018a35a0edff 100644 +index 7fa6c3e71b01166e563bf33c1c8606b116930ebe..30d76626bd13cfa99df99f2c1346aaac2df339a0 100644 --- a/src/main/java/net/minecraft/world/entity/EntityInsentient.java +++ b/src/main/java/net/minecraft/world/entity/EntityInsentient.java @@ -46,8 +46,6 @@ import net.minecraft.world.entity.ai.sensing.EntitySenses; @@ -3147,7 +3147,7 @@ index 3fff101637708a1a12f9a457bd3512ae94a8f884..b2d1a0144353a1da61221b59a0acc028 this.bF.b(this); } diff --git a/src/main/java/net/minecraft/world/entity/boss/wither/EntityWither.java b/src/main/java/net/minecraft/world/entity/boss/wither/EntityWither.java -index 930fc752ec0a988b17bc556cd428161638a14f27..73875b925cbf527f91a7c0ec09d350a7a2ec1260 100644 +index c056c4c09297602c1fb3c1040ac2ab0ec4c0139b..69e88d83dda260a95380369d546253982de4a2fd 100644 --- a/src/main/java/net/minecraft/world/entity/boss/wither/EntityWither.java +++ b/src/main/java/net/minecraft/world/entity/boss/wither/EntityWither.java @@ -12,6 +12,7 @@ import net.minecraft.network.chat.IChatBaseComponent; @@ -4119,7 +4119,7 @@ index d53e2a9d27f9976d1fd8ea30b88a0da089aec7b6..66ae664add95f4441724b49a470a2fef Vec3D vec3d = new Vec3D(this.b - this.i.locX(), this.c - this.i.locY(), this.d - this.i.locZ()); double d0 = vec3d.f(); diff --git a/src/main/java/net/minecraft/world/entity/monster/EntityGuardianElder.java b/src/main/java/net/minecraft/world/entity/monster/EntityGuardianElder.java -index 9bd6f5d988c1e50e1bb729c407178b9cbcc62115..16b8606be2835dccdfa75f29827be4b88aaa1810 100644 +index 300efeb98bb68b24faa68a4af9d703bf2b8c405c..ef48184f79920f053d62d34cc7b56a98e8aa4274 100644 --- a/src/main/java/net/minecraft/world/entity/monster/EntityGuardianElder.java +++ b/src/main/java/net/minecraft/world/entity/monster/EntityGuardianElder.java @@ -30,6 +30,18 @@ public class EntityGuardianElder extends EntityGuardian { @@ -5326,7 +5326,7 @@ index 9aa4850e021076fde306eea7eec104c31086c57f..c2e32121f693a6207e6239c26a1fd6e6 this.world.getMethodProfiler().exit(); HoglinAI.a(this); diff --git a/src/main/java/net/minecraft/world/entity/monster/piglin/EntityPiglin.java b/src/main/java/net/minecraft/world/entity/monster/piglin/EntityPiglin.java -index 4ee979a2771b1c97379a77af34b9e7b6de34d67b..4021174b3c0bcbe582354fc72697e1123d3a9627 100644 +index 99cdcc9a9a7e6227a165c4ef779f8e76a99ec56a..a2e90d890dfe62666c79969b9de9d9cd78ee2cf3 100644 --- a/src/main/java/net/minecraft/world/entity/monster/piglin/EntityPiglin.java +++ b/src/main/java/net/minecraft/world/entity/monster/piglin/EntityPiglin.java @@ -86,6 +86,18 @@ public class EntityPiglin extends EntityPiglinAbstract implements ICrossbow { @@ -5399,7 +5399,7 @@ index 3d85501791fce621335f34bf508becb74b80210d..1370d2d8568a4ed62f2ec3d54abc7d2b PiglinBruteAI.b(this); PiglinBruteAI.c(this); diff --git a/src/main/java/net/minecraft/world/entity/npc/EntityVillager.java b/src/main/java/net/minecraft/world/entity/npc/EntityVillager.java -index 9c187b015c9acd11a372ec4844bc6d5ead4ca73d..daad6520c5d20646f34895225fbf669ecb18e72b 100644 +index fd25524e36317f69091150a85b5068fb6bcf189a..a9a2caadca0f93438a4ad8e21d2e5ff5a98aa3fd 100644 --- a/src/main/java/net/minecraft/world/entity/npc/EntityVillager.java +++ b/src/main/java/net/minecraft/world/entity/npc/EntityVillager.java @@ -32,6 +32,7 @@ import net.minecraft.network.syncher.DataWatcherObject; diff --git a/patches/Purpur/patches/server/0104-Entities-can-use-portals-configuration.patch b/patches/Purpur/patches/server/0104-Entities-can-use-portals-configuration.patch index 6bd7fb53..d2c05eea 100644 --- a/patches/Purpur/patches/server/0104-Entities-can-use-portals-configuration.patch +++ b/patches/Purpur/patches/server/0104-Entities-can-use-portals-configuration.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Entities can use portals configuration diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java -index 668f613a901523e87780f33ffff565d965521783..7bab5b730486b1f22246c39d581c69a43f85a984 100644 +index 7856e81266c9b63eebeb7b302e64c1c697841aae..90b8e9d7fb97b410cb4b7b555033ce3f14acba78 100644 --- a/src/main/java/net/minecraft/world/entity/Entity.java +++ b/src/main/java/net/minecraft/world/entity/Entity.java -@@ -2553,7 +2553,7 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, ne +@@ -2585,7 +2585,7 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, ne public void d(BlockPosition blockposition) { if (this.ai()) { this.resetPortalCooldown(); @@ -17,7 +17,7 @@ index 668f613a901523e87780f33ffff565d965521783..7bab5b730486b1f22246c39d581c69a4 if (!this.world.isClientSide && !blockposition.equals(this.ac)) { this.ac = blockposition.immutableCopy(); } -@@ -3133,7 +3133,7 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, ne +@@ -3166,7 +3166,7 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, ne } public boolean canPortal() { diff --git a/patches/Purpur/patches/server/0105-LivingEntity-broadcastItemBreak.patch b/patches/Purpur/patches/server/0105-LivingEntity-broadcastItemBreak.patch index 58ef9f17..fb1be999 100644 --- a/patches/Purpur/patches/server/0105-LivingEntity-broadcastItemBreak.patch +++ b/patches/Purpur/patches/server/0105-LivingEntity-broadcastItemBreak.patch @@ -5,10 +5,10 @@ Subject: [PATCH] LivingEntity#broadcastItemBreak diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java -index d99ab01298c7e35eae806af8fc60d5beba89c826..cf79f39fc8071d86f7455681e41b3eab1826cb35 100644 +index a248c6ac0eb9bcc8c3dbd38ead35104b9580d427..670b5bee5771aee90cd241426db319fa627d578c 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java -@@ -870,5 +870,11 @@ public class CraftLivingEntity extends CraftEntity implements LivingEntity { +@@ -875,5 +875,11 @@ public class CraftLivingEntity extends CraftEntity implements LivingEntity { public void setSafeFallDistance(float safeFallDistance) { getHandle().safeFallDistance = safeFallDistance; } diff --git a/patches/Purpur/patches/server/0106-Customizable-wither-health-and-healing.patch b/patches/Purpur/patches/server/0106-Customizable-wither-health-and-healing.patch index e005eacf..b52f4cff 100644 --- a/patches/Purpur/patches/server/0106-Customizable-wither-health-and-healing.patch +++ b/patches/Purpur/patches/server/0106-Customizable-wither-health-and-healing.patch @@ -6,7 +6,7 @@ Subject: [PATCH] Customizable wither health and healing Adds the ability to customize the health of the wither, as well as the amount that it heals, and how often. diff --git a/src/main/java/net/minecraft/world/entity/boss/wither/EntityWither.java b/src/main/java/net/minecraft/world/entity/boss/wither/EntityWither.java -index 73875b925cbf527f91a7c0ec09d350a7a2ec1260..34103234140d61a5dc1d3e9f575fb8a65cde956b 100644 +index 69e88d83dda260a95380369d546253982de4a2fd..0c4446c0246d80394dd278b5fe2f1136ce7e90b0 100644 --- a/src/main/java/net/minecraft/world/entity/boss/wither/EntityWither.java +++ b/src/main/java/net/minecraft/world/entity/boss/wither/EntityWither.java @@ -205,6 +205,11 @@ public class EntityWither extends EntityMonster implements IRangedEntity { diff --git a/patches/Purpur/patches/server/0115-Stonecutter-damage.patch b/patches/Purpur/patches/server/0115-Stonecutter-damage.patch index 1ec8500b..d38b75d0 100644 --- a/patches/Purpur/patches/server/0115-Stonecutter-damage.patch +++ b/patches/Purpur/patches/server/0115-Stonecutter-damage.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Stonecutter damage diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java -index 7bab5b730486b1f22246c39d581c69a43f85a984..a3333b7d1e55f6cbcdc20072b27df384e50c61d5 100644 +index 90b8e9d7fb97b410cb4b7b555033ce3f14acba78..a586f486996b3bb59067a6d25ace100c24b63ecf 100644 --- a/src/main/java/net/minecraft/world/entity/Entity.java +++ b/src/main/java/net/minecraft/world/entity/Entity.java -@@ -893,7 +893,7 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, ne +@@ -925,7 +925,7 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, ne } // CraftBukkit end diff --git a/patches/Purpur/patches/server/0129-Add-critical-hit-check-to-EntityDamagedByEntityEvent.patch b/patches/Purpur/patches/server/0129-Add-critical-hit-check-to-EntityDamagedByEntityEvent.patch index 2cc229e1..cb267fd4 100644 --- a/patches/Purpur/patches/server/0129-Add-critical-hit-check-to-EntityDamagedByEntityEvent.patch +++ b/patches/Purpur/patches/server/0129-Add-critical-hit-check-to-EntityDamagedByEntityEvent.patch @@ -33,9 +33,27 @@ index a70c557de56c5ba04cb520108cdb037eb9cad8a9..78442fe87ceaf65b302536c893610aa0 if (flag5) { if (i > 0) { diff --git a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java -index c4218281721cf4a5b8f2cad5e12089e3aee89737..cfeb80b889b84f9de65c4d5ba50bd76019c16ef0 100644 +index c4218281721cf4a5b8f2cad5e12089e3aee89737..c07ff0cc7cae358c3fd772d24c2944cc92e1acff 100644 --- a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java +++ b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java +@@ -962,7 +962,7 @@ public class CraftEventFactory { + } else { + damageCause = DamageCause.ENTITY_EXPLOSION; + } +- event = new EntityDamageByEntityEvent(damager.getBukkitEntity(), entity.getBukkitEntity(), damageCause, modifiers, modifierFunctions); ++ event = new EntityDamageByEntityEvent(damager.getBukkitEntity(), entity.getBukkitEntity(), damageCause, modifiers, modifierFunctions, damager instanceof HumanEntity && ((EntityHuman)damager).isCritical); // Purpur + damager.processClick(EnumHand.MAIN_HAND); // Purpur + } + event.setCancelled(cancelled); +@@ -1042,7 +1042,7 @@ public class CraftEventFactory { + } else { + throw new IllegalStateException(String.format("Unhandled damage of %s by %s from %s", entity, damager.getHandle(), source.translationIndex)); + } +- EntityDamageEvent event = new EntityDamageByEntityEvent(damager, entity.getBukkitEntity(), cause, modifiers, modifierFunctions); ++ EntityDamageEvent event = new EntityDamageByEntityEvent(damager, entity.getBukkitEntity(), cause, modifiers, modifierFunctions, entityDamage instanceof HumanEntity && ((EntityHuman)entityDamage).isCritical); // Purpur + event.setCancelled(cancelled); + callEvent(event); + if (!event.isCancelled()) { @@ -1097,7 +1097,7 @@ public class CraftEventFactory { private static EntityDamageEvent callEntityDamageEvent(Entity damager, Entity damagee, DamageCause cause, Map modifiers, Map> modifierFunctions, boolean cancelled) { EntityDamageEvent event; diff --git a/patches/Purpur/patches/server/0135-Changeable-Mob-Left-Handed-Chance.patch b/patches/Purpur/patches/server/0135-Changeable-Mob-Left-Handed-Chance.patch index 4a8fc4ea..760e2f8e 100644 --- a/patches/Purpur/patches/server/0135-Changeable-Mob-Left-Handed-Chance.patch +++ b/patches/Purpur/patches/server/0135-Changeable-Mob-Left-Handed-Chance.patch @@ -5,7 +5,7 @@ Subject: [PATCH] Changeable Mob Left Handed Chance diff --git a/src/main/java/net/minecraft/world/entity/EntityInsentient.java b/src/main/java/net/minecraft/world/entity/EntityInsentient.java -index dd1f4c4202e30a837b48b591327b018a35a0edff..4da6e2dd956a44d7cd47a234f1b251c930722015 100644 +index 30d76626bd13cfa99df99f2c1346aaac2df339a0..1f2b7727a49aa75987baf2de3f408d0ded007fa7 100644 --- a/src/main/java/net/minecraft/world/entity/EntityInsentient.java +++ b/src/main/java/net/minecraft/world/entity/EntityInsentient.java @@ -1217,7 +1217,7 @@ public abstract class EntityInsentient extends EntityLiving { diff --git a/patches/Purpur/patches/server/0139-PaperPR-Config-option-for-Piglins-guarding-chests.patch b/patches/Purpur/patches/server/0139-PaperPR-Config-option-for-Piglins-guarding-chests.patch index 9b87f3d4..fcab62c1 100644 --- a/patches/Purpur/patches/server/0139-PaperPR-Config-option-for-Piglins-guarding-chests.patch +++ b/patches/Purpur/patches/server/0139-PaperPR-Config-option-for-Piglins-guarding-chests.patch @@ -5,7 +5,7 @@ Subject: [PATCH] PaperPR - Config option for Piglins guarding chests diff --git a/src/main/java/com/destroystokyo/paper/PaperWorldConfig.java b/src/main/java/com/destroystokyo/paper/PaperWorldConfig.java -index 795b76379eb698aa0ed83c000ea0679a844792d5..577ed19fa8875ab37433b1061f055521a4245434 100644 +index 1a368df78feb4afdf522527af5ed1652afffcd15..aaeb6396597ddce3a2eebf7d76c7d1e654300f0b 100644 --- a/src/main/java/com/destroystokyo/paper/PaperWorldConfig.java +++ b/src/main/java/com/destroystokyo/paper/PaperWorldConfig.java @@ -704,6 +704,11 @@ public class PaperWorldConfig { @@ -21,7 +21,7 @@ index 795b76379eb698aa0ed83c000ea0679a844792d5..577ed19fa8875ab37433b1061f055521 private void useEigencraftRedstone() { useEigencraftRedstone = this.getBoolean("use-faster-eigencraft-redstone", false); diff --git a/src/main/java/net/minecraft/world/entity/monster/piglin/PiglinAI.java b/src/main/java/net/minecraft/world/entity/monster/piglin/PiglinAI.java -index f2102a970f4bbb49b8206dd8577349b62bf355f7..5b4c32dd8c634c73273bacd5629dff1df35ac132 100644 +index 44ecce39996cc4e7baad543803e1b5cfc22f8cf0..b7213d5a9c3d0f60a8f8f725cef6506d5b22d0ed 100644 --- a/src/main/java/net/minecraft/world/entity/monster/piglin/PiglinAI.java +++ b/src/main/java/net/minecraft/world/entity/monster/piglin/PiglinAI.java @@ -437,6 +437,7 @@ public class PiglinAI { diff --git a/patches/Purpur/patches/server/0142-Lobotomize-stuck-villagers.patch b/patches/Purpur/patches/server/0142-Lobotomize-stuck-villagers.patch index 75764160..0dcc26c1 100644 --- a/patches/Purpur/patches/server/0142-Lobotomize-stuck-villagers.patch +++ b/patches/Purpur/patches/server/0142-Lobotomize-stuck-villagers.patch @@ -5,7 +5,7 @@ Subject: [PATCH] Lobotomize stuck villagers diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java -index a3333b7d1e55f6cbcdc20072b27df384e50c61d5..ebdeb74a882f5f70214e6adfd83c5254dab29a5a 100644 +index a586f486996b3bb59067a6d25ace100c24b63ecf..829dc166548c7fc2890aa4abb5906586b448306f 100644 --- a/src/main/java/net/minecraft/world/entity/Entity.java +++ b/src/main/java/net/minecraft/world/entity/Entity.java @@ -206,7 +206,7 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, ne @@ -30,7 +30,7 @@ index 48e6a4c588ef39a4bde067d79b96a656c68750ce..ac7bad10697c6fde7d512753992d5971 // Paper start - add target parameter return this.a(blockposition, null, i); diff --git a/src/main/java/net/minecraft/world/entity/npc/EntityVillager.java b/src/main/java/net/minecraft/world/entity/npc/EntityVillager.java -index daad6520c5d20646f34895225fbf669ecb18e72b..01cfb29db6c9d42530e4113d6ae2384743018f70 100644 +index a9a2caadca0f93438a4ad8e21d2e5ff5a98aa3fd..539a338081bd532779b7f6ec15cc91ab5bd1cca9 100644 --- a/src/main/java/net/minecraft/world/entity/npc/EntityVillager.java +++ b/src/main/java/net/minecraft/world/entity/npc/EntityVillager.java @@ -89,6 +89,7 @@ import net.minecraft.world.level.IWorldReader; diff --git a/patches/Purpur/patches/server/0143-Option-for-Villager-Clerics-to-farm-Nether-Wart.patch b/patches/Purpur/patches/server/0143-Option-for-Villager-Clerics-to-farm-Nether-Wart.patch index 2bfef1db..27cde524 100644 --- a/patches/Purpur/patches/server/0143-Option-for-Villager-Clerics-to-farm-Nether-Wart.patch +++ b/patches/Purpur/patches/server/0143-Option-for-Villager-Clerics-to-farm-Nether-Wart.patch @@ -186,7 +186,7 @@ index 25c10973c74f98224dd1d2ae5e7178b9781374aa..d50b5632f0e53147ea23109f1ed627b4 behaviorcontroller.removeMemory(MemoryModuleType.SECONDARY_JOB_SITE); } diff --git a/src/main/java/net/minecraft/world/entity/npc/EntityVillager.java b/src/main/java/net/minecraft/world/entity/npc/EntityVillager.java -index 01cfb29db6c9d42530e4113d6ae2384743018f70..19c90ba0342ac2e38ae31fb1440b37e24df43f18 100644 +index 539a338081bd532779b7f6ec15cc91ab5bd1cca9..56f45267919c8c7722f1cde29a4ac18c7f5f1069 100644 --- a/src/main/java/net/minecraft/world/entity/npc/EntityVillager.java +++ b/src/main/java/net/minecraft/world/entity/npc/EntityVillager.java @@ -203,7 +203,7 @@ public class EntityVillager extends EntityVillagerAbstract implements Reputation @@ -198,7 +198,7 @@ index 01cfb29db6c9d42530e4113d6ae2384743018f70..19c90ba0342ac2e38ae31fb1440b37e2 } behaviorcontroller.a(Activity.CORE, Behaviors.a(villagerprofession, 0.5F)); -@@ -953,6 +953,11 @@ public class EntityVillager extends EntityVillagerAbstract implements Reputation +@@ -951,6 +951,11 @@ public class EntityVillager extends EntityVillagerAbstract implements Reputation } public boolean canPlant() { diff --git a/patches/Purpur/patches/server/0148-Configurable-entity-base-attributes.patch b/patches/Purpur/patches/server/0148-Configurable-entity-base-attributes.patch index 3de99010..0a996fca 100644 --- a/patches/Purpur/patches/server/0148-Configurable-entity-base-attributes.patch +++ b/patches/Purpur/patches/server/0148-Configurable-entity-base-attributes.patch @@ -869,7 +869,7 @@ index 66ae664add95f4441724b49a470a2fef569042d6..291b2e0defe4d63d4f746a3879c1fee5 @Override diff --git a/src/main/java/net/minecraft/world/entity/monster/EntityGuardianElder.java b/src/main/java/net/minecraft/world/entity/monster/EntityGuardianElder.java -index 16b8606be2835dccdfa75f29827be4b88aaa1810..b06897c3d9dfc4612b0711eee5f225224e07ae91 100644 +index ef48184f79920f053d62d34cc7b56a98e8aa4274..4ce2880c063e3552febd05dc7f38cb17cbb1b4d7 100644 --- a/src/main/java/net/minecraft/world/entity/monster/EntityGuardianElder.java +++ b/src/main/java/net/minecraft/world/entity/monster/EntityGuardianElder.java @@ -40,6 +40,11 @@ public class EntityGuardianElder extends EntityGuardian { @@ -1335,7 +1335,7 @@ index 8c2815c8b11c8db8e6c1d0caf71188322e52094d..0b6c80e908392025197b68d1ba6b3eed @Override diff --git a/src/main/java/net/minecraft/world/entity/monster/piglin/EntityPiglin.java b/src/main/java/net/minecraft/world/entity/monster/piglin/EntityPiglin.java -index 4021174b3c0bcbe582354fc72697e1123d3a9627..1f2f836284c52cf3e7ff295a538f88d95e088761 100644 +index a2e90d890dfe62666c79969b9de9d9cd78ee2cf3..4f2c26ea34c82ec7c4f8ff92dd2e8a1f56a1afa6 100644 --- a/src/main/java/net/minecraft/world/entity/monster/piglin/EntityPiglin.java +++ b/src/main/java/net/minecraft/world/entity/monster/piglin/EntityPiglin.java @@ -96,6 +96,11 @@ public class EntityPiglin extends EntityPiglinAbstract implements ICrossbow { @@ -1367,7 +1367,7 @@ index 1370d2d8568a4ed62f2ec3d54abc7d2bebc48f75..201b78ffb5062254a6b3447f217df03d public static AttributeProvider.Builder eS() { diff --git a/src/main/java/net/minecraft/world/entity/npc/EntityVillager.java b/src/main/java/net/minecraft/world/entity/npc/EntityVillager.java -index 19c90ba0342ac2e38ae31fb1440b37e24df43f18..0c37f2cb72438b2b0114a231a7766ecdc8ac3064 100644 +index 56f45267919c8c7722f1cde29a4ac18c7f5f1069..1b078f259ccfe480f688d9724bb0a2b4e672eec6 100644 --- a/src/main/java/net/minecraft/world/entity/npc/EntityVillager.java +++ b/src/main/java/net/minecraft/world/entity/npc/EntityVillager.java @@ -167,6 +167,11 @@ public class EntityVillager extends EntityVillagerAbstract implements Reputation diff --git a/patches/Purpur/patches/server/0151-Implement-TPSBar.patch b/patches/Purpur/patches/server/0151-Implement-TPSBar.patch index 7ba0fc9c..6f4a6bdc 100644 --- a/patches/Purpur/patches/server/0151-Implement-TPSBar.patch +++ b/patches/Purpur/patches/server/0151-Implement-TPSBar.patch @@ -17,7 +17,7 @@ index 0ea56c863a9a1019b36f7f9f9164301aef12637b..4338b459011bf7a083790b7bb76cf1b2 if (commanddispatcher_servertype.d) { diff --git a/src/main/java/net/minecraft/server/MinecraftServer.java b/src/main/java/net/minecraft/server/MinecraftServer.java -index 6c0729b0b2a956607067885768cbe848d7406ad6..f9a5b96bf479c177f6a2f2a45258990c297ea3b8 100644 +index 45722de76788886efa664b1b4124903bf6870e7c..6a561f0a6e076350b96212a1219a9658c4da6531 100644 --- a/src/main/java/net/minecraft/server/MinecraftServer.java +++ b/src/main/java/net/minecraft/server/MinecraftServer.java @@ -993,6 +993,7 @@ public abstract class MinecraftServer extends IAsyncTaskHandlerReentrant. diff --git a/src/main/java/net/minecraft/world/level/block/BlockEnderPortal.java b/src/main/java/net/minecraft/world/level/block/BlockEnderPortal.java -index ed916f69747b44b75eb06db4cf27adaf5e47fd1e..80aad27c2475535f22077a1674114eebfadbd711 100644 +index 2ad7d6809beff6b5a36b32ba29d05447139a415e..0a8be3cd179388f041f31d7e4706619da879b3f5 100644 --- a/src/main/java/net/minecraft/world/level/block/BlockEnderPortal.java +++ b/src/main/java/net/minecraft/world/level/block/BlockEnderPortal.java @@ -44,7 +44,15 @@ public class BlockEnderPortal extends BlockTileEntity { diff --git a/patches/Purpur/patches/server/0161-Movement-options-for-armor-stands.patch b/patches/Purpur/patches/server/0161-Movement-options-for-armor-stands.patch index a0bd6b69..b1f4a131 100644 --- a/patches/Purpur/patches/server/0161-Movement-options-for-armor-stands.patch +++ b/patches/Purpur/patches/server/0161-Movement-options-for-armor-stands.patch @@ -17,10 +17,10 @@ You should have received a copy of the GNU General Public License along with this program. If not, see . diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java -index ebdeb74a882f5f70214e6adfd83c5254dab29a5a..1b381125b16f231686b507985807028824b9d441 100644 +index 829dc166548c7fc2890aa4abb5906586b448306f..7326d63874e7e1be7d8649c9a4d3bdaa2d0b195f 100644 --- a/src/main/java/net/minecraft/world/entity/Entity.java +++ b/src/main/java/net/minecraft/world/entity/Entity.java -@@ -1499,7 +1499,7 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, ne +@@ -1531,7 +1531,7 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, ne return this.isInWater() || flag; } diff --git a/patches/Purpur/patches/server/0162-Fix-stuck-in-portals.patch b/patches/Purpur/patches/server/0162-Fix-stuck-in-portals.patch index 62172e6d..9e564ec2 100644 --- a/patches/Purpur/patches/server/0162-Fix-stuck-in-portals.patch +++ b/patches/Purpur/patches/server/0162-Fix-stuck-in-portals.patch @@ -17,10 +17,10 @@ index 8a7f75baa730729dd0022fe74da15fe669eced24..c69ef7ee5e40e2557b3a3971c6fb24c9 // CraftBukkit end this.spawnIn(worldserver); diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java -index 1b381125b16f231686b507985807028824b9d441..6cbd6b38ac77dac8ecde224849f74a6f5a4f9d98 100644 +index 7326d63874e7e1be7d8649c9a4d3bdaa2d0b195f..66754d478fac391dd16d1f9506720cd295d17f9c 100644 --- a/src/main/java/net/minecraft/world/entity/Entity.java +++ b/src/main/java/net/minecraft/world/entity/Entity.java -@@ -2550,12 +2550,15 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, ne +@@ -2582,12 +2582,15 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, ne return new Vec2F(this.pitch, this.yaw); } diff --git a/patches/Purpur/patches/server/0164-Toggle-for-water-sensitive-mob-damage.patch b/patches/Purpur/patches/server/0164-Toggle-for-water-sensitive-mob-damage.patch index f64db131..dba6f9b3 100644 --- a/patches/Purpur/patches/server/0164-Toggle-for-water-sensitive-mob-damage.patch +++ b/patches/Purpur/patches/server/0164-Toggle-for-water-sensitive-mob-damage.patch @@ -5,7 +5,7 @@ Subject: [PATCH] Toggle for water sensitive mob damage diff --git a/src/main/java/net/minecraft/world/entity/EntityInsentient.java b/src/main/java/net/minecraft/world/entity/EntityInsentient.java -index 4da6e2dd956a44d7cd47a234f1b251c930722015..b69bc34bfc4873dc2214aea19bfa877c37740418 100644 +index 1f2b7727a49aa75987baf2de3f408d0ded007fa7..36d6e5bf608c6f69a76932bed41a64f58e1e8b72 100644 --- a/src/main/java/net/minecraft/world/entity/EntityInsentient.java +++ b/src/main/java/net/minecraft/world/entity/EntityInsentient.java @@ -861,7 +861,8 @@ public abstract class EntityInsentient extends EntityLiving { diff --git a/patches/Purpur/patches/server/0169-Configs-for-if-Wither-Ender-Dragon-can-ride-vehicles.patch b/patches/Purpur/patches/server/0169-Configs-for-if-Wither-Ender-Dragon-can-ride-vehicles.patch index c7e26012..76251263 100644 --- a/patches/Purpur/patches/server/0169-Configs-for-if-Wither-Ender-Dragon-can-ride-vehicles.patch +++ b/patches/Purpur/patches/server/0169-Configs-for-if-Wither-Ender-Dragon-can-ride-vehicles.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Configs for if Wither/Ender Dragon can ride vehicles diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java -index 6cbd6b38ac77dac8ecde224849f74a6f5a4f9d98..e915905af690124f17407876c0fb854750f5db71 100644 +index 66754d478fac391dd16d1f9506720cd295d17f9c..666f5a2e5fe82a283dfcb1f25ed58d0a971c73d3 100644 --- a/src/main/java/net/minecraft/world/entity/Entity.java +++ b/src/main/java/net/minecraft/world/entity/Entity.java -@@ -2400,7 +2400,7 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, ne +@@ -2432,7 +2432,7 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, ne } } @@ -30,7 +30,7 @@ index 0614483830336f3bbd348319ca3eed8767568852..d27f61959e924e1ce6c7d76c905d98a7 } diff --git a/src/main/java/net/minecraft/world/entity/boss/wither/EntityWither.java b/src/main/java/net/minecraft/world/entity/boss/wither/EntityWither.java -index 9a152b7cd351380e696640a51e5f8b64225f25f0..e34e25d62bd677fc7373e73b4118898a4f7f4d26 100644 +index 4d201127c6718883fd8b5a3a2202cf62a098fc33..92f22271c76ed01b1c82608b1ff32c17cdb2145f 100644 --- a/src/main/java/net/minecraft/world/entity/boss/wither/EntityWither.java +++ b/src/main/java/net/minecraft/world/entity/boss/wither/EntityWither.java @@ -728,6 +728,7 @@ public class EntityWither extends EntityMonster implements IRangedEntity { diff --git a/patches/Purpur/patches/server/0183-Add-config-for-villager-trading.patch b/patches/Purpur/patches/server/0183-Add-config-for-villager-trading.patch index a5e74694..ec59bd66 100644 --- a/patches/Purpur/patches/server/0183-Add-config-for-villager-trading.patch +++ b/patches/Purpur/patches/server/0183-Add-config-for-villager-trading.patch @@ -5,7 +5,7 @@ Subject: [PATCH] Add config for villager trading diff --git a/src/main/java/net/minecraft/world/entity/npc/EntityVillager.java b/src/main/java/net/minecraft/world/entity/npc/EntityVillager.java -index 0c37f2cb72438b2b0114a231a7766ecdc8ac3064..e042af3f78a25587ba14d5fd9e346805dd5f1e85 100644 +index 1b078f259ccfe480f688d9724bb0a2b4e672eec6..aefa40a09015e243664a531dbf31c6b1ff1d00e7 100644 --- a/src/main/java/net/minecraft/world/entity/npc/EntityVillager.java +++ b/src/main/java/net/minecraft/world/entity/npc/EntityVillager.java @@ -373,7 +373,7 @@ public class EntityVillager extends EntityVillagerAbstract implements Reputation diff --git a/patches/Purpur/patches/server/0185-Drowning-Settings.patch b/patches/Purpur/patches/server/0185-Drowning-Settings.patch index 7ff930cc..2fb0ea5a 100644 --- a/patches/Purpur/patches/server/0185-Drowning-Settings.patch +++ b/patches/Purpur/patches/server/0185-Drowning-Settings.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Drowning Settings diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java -index e915905af690124f17407876c0fb854750f5db71..9325163e392213be1d51588b95361af63d294952 100644 +index 666f5a2e5fe82a283dfcb1f25ed58d0a971c73d3..feb5a6d8a534c4ee19940847cd53ff325335c4d6 100644 --- a/src/main/java/net/minecraft/world/entity/Entity.java +++ b/src/main/java/net/minecraft/world/entity/Entity.java -@@ -2605,7 +2605,7 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, ne +@@ -2638,7 +2638,7 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, ne } public int getDefaultPortalCooldown() { diff --git a/patches/Purpur/patches/server/0196-Configurable-damage-settings-for-magma-blocks.patch b/patches/Purpur/patches/server/0196-Configurable-damage-settings-for-magma-blocks.patch index 84e02bb1..1dba24e5 100644 --- a/patches/Purpur/patches/server/0196-Configurable-damage-settings-for-magma-blocks.patch +++ b/patches/Purpur/patches/server/0196-Configurable-damage-settings-for-magma-blocks.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Configurable damage settings for magma blocks diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java -index 9325163e392213be1d51588b95361af63d294952..4f0b8d966ba38672a39f95d1f6f55f95cdc8d334 100644 +index feb5a6d8a534c4ee19940847cd53ff325335c4d6..ca07d4caf9f7d82d8ca3d607f48d6eb2b7b60f39 100644 --- a/src/main/java/net/minecraft/world/entity/Entity.java +++ b/src/main/java/net/minecraft/world/entity/Entity.java -@@ -893,7 +893,7 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, ne +@@ -925,7 +925,7 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, ne } // CraftBukkit end diff --git a/patches/Purpur/patches/server/0203-Fix-SPIGOT-6278.patch b/patches/Purpur/patches/server/0203-Fix-SPIGOT-6278.patch index 8c6800e8..09e02de4 100644 --- a/patches/Purpur/patches/server/0203-Fix-SPIGOT-6278.patch +++ b/patches/Purpur/patches/server/0203-Fix-SPIGOT-6278.patch @@ -5,7 +5,7 @@ Subject: [PATCH] Fix SPIGOT-6278 diff --git a/src/main/java/net/minecraft/world/entity/monster/piglin/EntityPiglin.java b/src/main/java/net/minecraft/world/entity/monster/piglin/EntityPiglin.java -index 1f2f836284c52cf3e7ff295a538f88d95e088761..c8bb46f7331b07364ebbf9fbea9a6d2583c3ccb6 100644 +index 4f2c26ea34c82ec7c4f8ff92dd2e8a1f56a1afa6..42230ba14371ecb39c971f3a2969d1522c0fabc0 100644 --- a/src/main/java/net/minecraft/world/entity/monster/piglin/EntityPiglin.java +++ b/src/main/java/net/minecraft/world/entity/monster/piglin/EntityPiglin.java @@ -200,7 +200,7 @@ public class EntityPiglin extends EntityPiglinAbstract implements ICrossbow { diff --git a/patches/Purpur/patches/server/0215-ShulkerBox-allow-oversized-stacks.patch b/patches/Purpur/patches/server/0215-ShulkerBox-allow-oversized-stacks.patch index 85bda9da..23b79c71 100644 --- a/patches/Purpur/patches/server/0215-ShulkerBox-allow-oversized-stacks.patch +++ b/patches/Purpur/patches/server/0215-ShulkerBox-allow-oversized-stacks.patch @@ -22,7 +22,7 @@ index 7302554063ac7b5dedaff895cba33b70234008e6..151da6c134f908d9037fddc5b54e71b0 } else { ItemStack itemstack = this.player.getItemInMainHand(); diff --git a/src/main/java/net/minecraft/world/level/block/BlockShulkerBox.java b/src/main/java/net/minecraft/world/level/block/BlockShulkerBox.java -index 2c1c6562efe8cdc079b4e353144d20c1e46355c5..1083060cc3e0168d362851c34a2f38bf93c6a5fe 100644 +index 2c1c6562efe8cdc079b4e353144d20c1e46355c5..af935a03d3677314cd367686d65e89b615af3f4f 100644 --- a/src/main/java/net/minecraft/world/level/block/BlockShulkerBox.java +++ b/src/main/java/net/minecraft/world/level/block/BlockShulkerBox.java @@ -110,7 +110,7 @@ public class BlockShulkerBox extends BlockTileEntity { @@ -30,7 +30,7 @@ index 2c1c6562efe8cdc079b4e353144d20c1e46355c5..1083060cc3e0168d362851c34a2f38bf TileEntityShulkerBox tileentityshulkerbox = (TileEntityShulkerBox) tileentity; - if (!world.isClientSide && entityhuman.isCreative() && !tileentityshulkerbox.isEmpty()) { -+ if (!world.isClientSide && (world.purpurConfig.shulkerBoxAllowOversizedStacks || entityhuman.isCreative()) && !tileentityshulkerbox.isEmpty()) { ++ if (!world.isClientSide && (world.purpurConfig.shulkerBoxAllowOversizedStacks || (entityhuman.isCreative() && !tileentityshulkerbox.isEmpty()))) { ItemStack itemstack = b(this.c()); NBTTagCompound nbttagcompound = tileentityshulkerbox.e(new NBTTagCompound()); diff --git a/patches/Purpur/patches/server/0217-API-for-any-mob-to-burn-daylight.patch b/patches/Purpur/patches/server/0217-API-for-any-mob-to-burn-daylight.patch index f52741e1..ce77eb13 100644 --- a/patches/Purpur/patches/server/0217-API-for-any-mob-to-burn-daylight.patch +++ b/patches/Purpur/patches/server/0217-API-for-any-mob-to-burn-daylight.patch @@ -6,10 +6,10 @@ Subject: [PATCH] API for any mob to burn daylight Co-authored by: Encode42 diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java -index 4f0b8d966ba38672a39f95d1f6f55f95cdc8d334..773b4cd8e0da1c0aff0c6efde6bd9e682b758a6e 100644 +index ca07d4caf9f7d82d8ca3d607f48d6eb2b7b60f39..8cdc1a6e66df7fc4dbe91f986034fd1196819fc7 100644 --- a/src/main/java/net/minecraft/world/entity/Entity.java +++ b/src/main/java/net/minecraft/world/entity/Entity.java -@@ -1642,7 +1642,7 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, ne +@@ -1674,7 +1674,7 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, ne } } @@ -18,7 +18,7 @@ index 4f0b8d966ba38672a39f95d1f6f55f95cdc8d334..773b4cd8e0da1c0aff0c6efde6bd9e68 BlockPosition.MutableBlockPosition blockposition_mutableblockposition = new BlockPosition.MutableBlockPosition(this.locX(), 0.0D, this.locZ()); if (this.world.isLoaded(blockposition_mutableblockposition)) { -@@ -3866,5 +3866,17 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, ne +@@ -3899,5 +3899,17 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, ne public boolean processClick(EnumHand hand) { return false; } @@ -37,7 +37,7 @@ index 4f0b8d966ba38672a39f95d1f6f55f95cdc8d334..773b4cd8e0da1c0aff0c6efde6bd9e68 // Purpur end } diff --git a/src/main/java/net/minecraft/world/entity/EntityInsentient.java b/src/main/java/net/minecraft/world/entity/EntityInsentient.java -index b69bc34bfc4873dc2214aea19bfa877c37740418..b895288e0aa49e5a1222f7c5897f3dc43ff946fe 100644 +index 36d6e5bf608c6f69a76932bed41a64f58e1e8b72..0b2f21aab06aca77110bf8c061692bb2f5c4cb46 100644 --- a/src/main/java/net/minecraft/world/entity/EntityInsentient.java +++ b/src/main/java/net/minecraft/world/entity/EntityInsentient.java @@ -1687,6 +1687,7 @@ public abstract class EntityInsentient extends EntityLiving { @@ -348,10 +348,10 @@ index af69023b241560031f6aa116561d7407b2502578..f0a16fae2ddba2e3deeb09f04c029724 // Purpur end } diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java -index cf79f39fc8071d86f7455681e41b3eab1826cb35..bbc88fa176612e265534a5432b2a73779bb8921b 100644 +index 670b5bee5771aee90cd241426db319fa627d578c..a226025852a9157a37ca05b8a5f1107d63a436dd 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java -@@ -876,5 +876,15 @@ public class CraftLivingEntity extends CraftEntity implements LivingEntity { +@@ -881,5 +881,15 @@ public class CraftLivingEntity extends CraftEntity implements LivingEntity { if (slot == null) return; getHandle().broadcastItemBreak(org.bukkit.craftbukkit.CraftEquipmentSlot.getNMS(slot)); } diff --git a/patches/Purpur/patches/server/0218-Fix-advancement-triggers-on-entity-death.patch b/patches/Purpur/patches/server/0218-Fix-advancement-triggers-on-entity-death.patch index d9998d87..6ea31292 100644 --- a/patches/Purpur/patches/server/0218-Fix-advancement-triggers-on-entity-death.patch +++ b/patches/Purpur/patches/server/0218-Fix-advancement-triggers-on-entity-death.patch @@ -16,7 +16,7 @@ restoring it back to the entity just before the criterion triggers run and then finally clearing the equipment again right after the criterion is done. diff --git a/src/main/java/net/minecraft/world/entity/EntityInsentient.java b/src/main/java/net/minecraft/world/entity/EntityInsentient.java -index b895288e0aa49e5a1222f7c5897f3dc43ff946fe..e4f5a5ffd25d4d4e427938a633675be46805af66 100644 +index 0b2f21aab06aca77110bf8c061692bb2f5c4cb46..25294a68771cd4c9b1617fa2b743521ccb99b36d 100644 --- a/src/main/java/net/minecraft/world/entity/EntityInsentient.java +++ b/src/main/java/net/minecraft/world/entity/EntityInsentient.java @@ -106,9 +106,9 @@ public abstract class EntityInsentient extends EntityLiving { diff --git a/patches/Tuinity/patches/api/0002-Tuinity-config.patch b/patches/Tuinity/patches/api/0002-Tuinity-config.patch index d1b967df..ccc33785 100644 --- a/patches/Tuinity/patches/api/0002-Tuinity-config.patch +++ b/patches/Tuinity/patches/api/0002-Tuinity-config.patch @@ -6,10 +6,10 @@ Subject: [PATCH] Tuinity config API to retrieve raw YamlConfiguration + timing exports diff --git a/src/main/java/org/bukkit/Server.java b/src/main/java/org/bukkit/Server.java -index 35ec8a060c2a2d2d48477b1bb940db51d18bf38e..d1a9322cf54f57f0d213145aa50c219f0eb2a90b 100644 +index e88b47a838dc472ad64271a518ee1789f7be19fa..f55ae8275c297c4c86215fba8d7197ffe9715879 100644 --- a/src/main/java/org/bukkit/Server.java +++ b/src/main/java/org/bukkit/Server.java -@@ -1595,6 +1595,14 @@ public interface Server extends PluginMessageRecipient, net.kyori.adventure.audi +@@ -1606,6 +1606,14 @@ public interface Server extends PluginMessageRecipient, net.kyori.adventure.audi } // Paper end diff --git a/patches/Tuinity/patches/server/0002-Brand-changes.patch b/patches/Tuinity/patches/server/0002-Brand-changes.patch index a963d536..3bb589bf 100644 --- a/patches/Tuinity/patches/server/0002-Brand-changes.patch +++ b/patches/Tuinity/patches/server/0002-Brand-changes.patch @@ -40,7 +40,7 @@ index a0f53c9eff04a40780b3ba568dbfc5bbe9bd8504..3bc5cd1e53dd7c94b948e7f57f0dc8e0 throwable = throwable1; throw throwable1; diff --git a/src/main/java/net/minecraft/server/MinecraftServer.java b/src/main/java/net/minecraft/server/MinecraftServer.java -index 03823e95e1fbf465ff5b3b2c5743f1beb25de083..a31ae036fba3873211805c8ced5e456e0aa7e26b 100644 +index bf80e870e6a2a6fe1d4ae1bea355bcd7a0735d3b..da66369c63e60e6e0328392b2eb98579613be63e 100644 --- a/src/main/java/net/minecraft/server/MinecraftServer.java +++ b/src/main/java/net/minecraft/server/MinecraftServer.java @@ -1583,7 +1583,7 @@ public abstract class MinecraftServer extends IAsyncTaskHandlerReentrant void mergeSortedSets(final java.util.function.Consumer consumer, final java.util.Comparator comparator, final java.util.SortedSet...sets) { final ObjectRBTreeSet all = new ObjectRBTreeSet<>(comparator); diff --git a/src/main/java/net/minecraft/server/MinecraftServer.java b/src/main/java/net/minecraft/server/MinecraftServer.java -index a31ae036fba3873211805c8ced5e456e0aa7e26b..b310a066c386aef1b227515f053b06094ebc0373 100644 +index da66369c63e60e6e0328392b2eb98579613be63e..200ec8ad168e5b5e3672a4284e851b06fcc706b0 100644 --- a/src/main/java/net/minecraft/server/MinecraftServer.java +++ b/src/main/java/net/minecraft/server/MinecraftServer.java @@ -268,6 +268,7 @@ public abstract class MinecraftServer extends IAsyncTaskHandlerReentrant(), diff --git a/src/main/java/net/minecraft/server/MinecraftServer.java b/src/main/java/net/minecraft/server/MinecraftServer.java -index c57c818c5aab61b66d8b40065c4d667b67e6d329..746be904a8408c2fa718d6e8352e50315f7bf362 100644 +index 594d6683b4bf74b83d44675e58a7d036d7572f61..7317a64269b8ce2a30117ebb23acfe98e1eeb281 100644 --- a/src/main/java/net/minecraft/server/MinecraftServer.java +++ b/src/main/java/net/minecraft/server/MinecraftServer.java @@ -1455,6 +1455,8 @@ public abstract class MinecraftServer extends IAsyncTaskHandlerReentrant +Date: Tue, 1 Jun 2021 15:35:31 -0700 +Subject: [PATCH] Fix dangerous end portal logic + +End portals could teleport entities during move calls. Stupid +logic given the caller will never expect that kind of thing, +and will result in all kinds of dupes. + +Move the tick logic into the post tick, where portaling was +designed to happen in the first place. + +diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java +index 6b6abf401cc7c7c79ffb472c35550596fc8e55b5..c3d4eda866016c4ac08d4c5d771e39dcac5a3a60 100644 +--- a/src/main/java/net/minecraft/world/entity/Entity.java ++++ b/src/main/java/net/minecraft/world/entity/Entity.java +@@ -370,6 +370,38 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, ne + } + // Tuinity end + ++ // Tuinity start - make end portalling safe ++ public BlockPosition portalBlock; ++ public WorldServer portalWorld; ++ public void tickEndPortal() { ++ BlockPosition pos = this.portalBlock; ++ WorldServer world = this.portalWorld; ++ this.portalBlock = null; ++ this.portalWorld = null; ++ ++ if (pos == null || world == null || world != this.world) { ++ return; ++ } ++ ++ if (this.isPassenger() || this.isVehicle() || !this.canPortal() || this.dead || !this.valid || !this.isAlive()) { ++ return; ++ } ++ ++ ResourceKey resourcekey = world.getTypeKey() == DimensionManager.THE_END ? World.OVERWORLD : World.THE_END; // CraftBukkit - SPIGOT-6152: send back to main overworld in custom ends ++ WorldServer worldserver = world.getMinecraftServer().getWorldServer(resourcekey); ++ ++ org.bukkit.event.entity.EntityPortalEnterEvent event = new org.bukkit.event.entity.EntityPortalEnterEvent(this.getBukkitEntity(), new org.bukkit.Location(world.getWorld(), pos.getX(), pos.getY(), pos.getZ())); ++ event.callEvent(); ++ ++ if (this instanceof EntityPlayer) { ++ ((EntityPlayer)this).b(worldserver, PlayerTeleportEvent.TeleportCause.END_PORTAL); ++ return; ++ } ++ // CraftBukkit end ++ this.b(worldserver); ++ } ++ // Tuinity end - make end portalling safe ++ + public Entity(EntityTypes entitytypes, World world) { + this.id = Entity.entityCount.incrementAndGet(); + this.passengers = Lists.newArrayList(); +@@ -2541,6 +2573,7 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, ne + } + + this.E(); ++ this.tickEndPortal(); // Tuinity - make end portalling safe + } + } + +diff --git a/src/main/java/net/minecraft/world/entity/boss/wither/EntityWither.java b/src/main/java/net/minecraft/world/entity/boss/wither/EntityWither.java +index 930fc752ec0a988b17bc556cd428161638a14f27..c056c4c09297602c1fb3c1040ac2ab0ec4c0139b 100644 +--- a/src/main/java/net/minecraft/world/entity/boss/wither/EntityWither.java ++++ b/src/main/java/net/minecraft/world/entity/boss/wither/EntityWither.java +@@ -603,7 +603,7 @@ public class EntityWither extends EntityMonster implements IRangedEntity { + + @Override + public boolean canPortal() { +- return canPortal; // Paper ++ return super.canPortal() && canPortal; // Paper // Tuinity - ensure super is called + } + + @Override +diff --git a/src/main/java/net/minecraft/world/level/block/BlockEnderPortal.java b/src/main/java/net/minecraft/world/level/block/BlockEnderPortal.java +index ed916f69747b44b75eb06db4cf27adaf5e47fd1e..2ad7d6809beff6b5a36b32ba29d05447139a415e 100644 +--- a/src/main/java/net/minecraft/world/level/block/BlockEnderPortal.java ++++ b/src/main/java/net/minecraft/world/level/block/BlockEnderPortal.java +@@ -52,16 +52,10 @@ public class BlockEnderPortal extends BlockTileEntity { + // return; // CraftBukkit - always fire event in case plugins wish to change it + } + +- // CraftBukkit start - Entity in portal +- EntityPortalEnterEvent event = new EntityPortalEnterEvent(entity.getBukkitEntity(), new org.bukkit.Location(world.getWorld(), blockposition.getX(), blockposition.getY(), blockposition.getZ())); +- world.getServer().getPluginManager().callEvent(event); +- +- if (entity instanceof EntityPlayer) { +- ((EntityPlayer) entity).b(worldserver, PlayerTeleportEvent.TeleportCause.END_PORTAL); +- return; +- } +- // CraftBukkit end +- entity.b(worldserver); ++ // Tuinity start - move all of this logic into portal tick ++ entity.portalWorld = ((WorldServer)world); ++ entity.portalBlock = blockposition.immutableCopy(); ++ // Tuinity end - move all of this logic into portal tick + } + + } diff --git a/patches/api/0002-Yatopia-Config-Redirect-Config.patch b/patches/api/0002-Yatopia-Config-Redirect-Config.patch index b61363fc..a1e368f9 100644 --- a/patches/api/0002-Yatopia-Config-Redirect-Config.patch +++ b/patches/api/0002-Yatopia-Config-Redirect-Config.patch @@ -5,10 +5,10 @@ Subject: [PATCH] Yatopia Config & Redirect Config diff --git a/src/main/java/org/bukkit/Server.java b/src/main/java/org/bukkit/Server.java -index 0f66655541dbb0dbb05a13a3612bb46cfb2b538a..a69bf7aae1e9d6b658b079431d23ca0f28c871d1 100644 +index a7fcd00ae37f9a2026759642562b1059c9dd9526..d756eb5ff47611a3edf616387c252e8c75207a21 100644 --- a/src/main/java/org/bukkit/Server.java +++ b/src/main/java/org/bukkit/Server.java -@@ -1618,6 +1618,22 @@ public interface Server extends PluginMessageRecipient, net.kyori.adventure.audi +@@ -1629,6 +1629,22 @@ public interface Server extends PluginMessageRecipient, net.kyori.adventure.audi } // Purpur end diff --git a/patches/api/0004-Add-last-tick-time-API.patch b/patches/api/0004-Add-last-tick-time-API.patch index 94c196a4..932e4e97 100644 --- a/patches/api/0004-Add-last-tick-time-API.patch +++ b/patches/api/0004-Add-last-tick-time-API.patch @@ -7,10 +7,10 @@ Original patch by: Co-authored-by: tr7zw diff --git a/src/main/java/org/bukkit/Bukkit.java b/src/main/java/org/bukkit/Bukkit.java -index 8036c66af0bc6b11ffd0f716138901bcfea007e1..5c11d5203491d120356098c14c0069874b2eaadf 100644 +index 194261bf20bb727d207a2429fa59abf0acf61b19..15203139858b09a5ba75545c0c19c89d48419a2c 100644 --- a/src/main/java/org/bukkit/Bukkit.java +++ b/src/main/java/org/bukkit/Bukkit.java -@@ -1971,4 +1971,14 @@ public final class Bukkit { +@@ -1983,4 +1983,14 @@ public final class Bukkit { return server.isLagging(); } // Purpur end @@ -26,10 +26,10 @@ index 8036c66af0bc6b11ffd0f716138901bcfea007e1..5c11d5203491d120356098c14c006987 + // Yatopia end } diff --git a/src/main/java/org/bukkit/Server.java b/src/main/java/org/bukkit/Server.java -index a69bf7aae1e9d6b658b079431d23ca0f28c871d1..423e94f44cd62eaa270ac44b1e3f49acc5fcce9d 100644 +index d756eb5ff47611a3edf616387c252e8c75207a21..8bebea38ce408afd7a0c7590625d63535fdb0960 100644 --- a/src/main/java/org/bukkit/Server.java +++ b/src/main/java/org/bukkit/Server.java -@@ -1760,4 +1760,24 @@ public interface Server extends PluginMessageRecipient, net.kyori.adventure.audi +@@ -1771,4 +1771,24 @@ public interface Server extends PluginMessageRecipient, net.kyori.adventure.audi */ boolean isLagging(); // Purpur end diff --git a/patches/api/0005-Add-NBT-API-as-a-first-class-lib.patch b/patches/api/0005-Add-NBT-API-as-a-first-class-lib.patch index 3fff9bed..bfb3a87e 100644 --- a/patches/api/0005-Add-NBT-API-as-a-first-class-lib.patch +++ b/patches/api/0005-Add-NBT-API-as-a-first-class-lib.patch @@ -129,10 +129,10 @@ index 62d8d7dbd4d602ca8cb00ff0cf1331583b398323..7cb395466babc84dd4ce1c91cbab7d13 + // Yatopia end } diff --git a/src/main/java/org/bukkit/inventory/ItemStack.java b/src/main/java/org/bukkit/inventory/ItemStack.java -index fceba6780a15c274c4689eccbeb6dfb2eee25ed9..1ba63c21245c4d4b9326b89ac83add9481fec243 100644 +index ac2967eac165d74c8ee7e0e9ac63124a10851a0e..df684f97b6258bfeeccc4e1692a62715a8c12833 100644 --- a/src/main/java/org/bukkit/inventory/ItemStack.java +++ b/src/main/java/org/bukkit/inventory/ItemStack.java -@@ -1548,4 +1548,42 @@ public class ItemStack implements Cloneable, ConfigurationSerializable, net.kyor +@@ -1555,4 +1555,42 @@ public class ItemStack implements Cloneable, ConfigurationSerializable, net.kyor return random.nextInt(unbreaking + 1) > 0; } // Purpur end diff --git a/patches/server/0002-Brandings.patch b/patches/server/0002-Brandings.patch index 7c7f0be6..5b6878f6 100644 --- a/patches/server/0002-Brandings.patch +++ b/patches/server/0002-Brandings.patch @@ -53,7 +53,7 @@ index a580b021c7d9727b82a67dedfc509c286feb8c7e..046b6a2f80b3a71437b088cada9dd23c serverModName = getString("settings.server-mod-name", serverModName); } diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java -index 560020bf1372f68186f78b53502e3d2c145ab098..3bf0e295f7e9a3593789f513863dabaf35f17281 100644 +index 28a7d8d3911bbc176c9aa0c4bd5e0f8ee3cea1a3..413d32ba0383eeb28d94bcab77bc2c5e63435225 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java @@ -230,7 +230,7 @@ import javax.annotation.Nullable; // Paper diff --git a/patches/server/0005-Add-last-tick-time-API.patch b/patches/server/0005-Add-last-tick-time-API.patch index eea18a41..9d10b897 100644 --- a/patches/server/0005-Add-last-tick-time-API.patch +++ b/patches/server/0005-Add-last-tick-time-API.patch @@ -7,7 +7,7 @@ Original patch by: Co-authored-by: tr7zw diff --git a/src/main/java/net/minecraft/server/MinecraftServer.java b/src/main/java/net/minecraft/server/MinecraftServer.java -index 3f33301c3349c1c04b869a001120d03697afae8d..08d4a2ef671ff750305df9d4c0cac0f2e9c89006 100644 +index 3e1e5e8b23a2d6a43deb37fafc0bdc7396f2a84a..7901775e03185cf2d16ccc3d6d8bc50b7687f4db 100644 --- a/src/main/java/net/minecraft/server/MinecraftServer.java +++ b/src/main/java/net/minecraft/server/MinecraftServer.java @@ -1068,6 +1068,8 @@ public abstract class MinecraftServer extends IAsyncTaskHandlerReentrant diff --git a/src/main/java/net/minecraft/server/MinecraftServer.java b/src/main/java/net/minecraft/server/MinecraftServer.java -index cda0f9bf15fead921ced0e984dc9cf80ead88286..ed4a8f34c0f48adb9d90e53ac5c9ca584e400a47 100644 +index afd8e7447ef94a8682b86abd293d4d5f29390058..f09bfa5e1ab83e9a6d4650c5fbe6059848f166c5 100644 --- a/src/main/java/net/minecraft/server/MinecraftServer.java +++ b/src/main/java/net/minecraft/server/MinecraftServer.java @@ -955,7 +955,9 @@ public abstract class MinecraftServer extends IAsyncTaskHandlerReentrant { // CraftBukkit end @@ -226,7 +226,7 @@ index 286e14bb39509328844e1f57d8faa04b20014f83..2ed54208faf35ea5b4ea8540e95886b5 }); vec3d = this.a(enumdirection_enumaxis, blockutil_rectangle1); -@@ -3447,6 +3460,7 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, ne +@@ -3480,6 +3493,7 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, ne } public boolean cl() { @@ -234,7 +234,7 @@ index 286e14bb39509328844e1f57d8faa04b20014f83..2ed54208faf35ea5b4ea8540e95886b5 boolean flag = this.au; this.au = false; -@@ -3650,7 +3664,7 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, ne +@@ -3683,7 +3697,7 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, ne for (int i2 = k; i2 < l; ++i2) { for (int j2 = i1; j2 < j1; ++j2) { blockposition_mutableblockposition.d(l1, i2, j2); diff --git a/patches/server/0064-lithium-shape.patch b/patches/server/0064-lithium-shape.patch index 4bf582a3..e603b7fb 100644 --- a/patches/server/0064-lithium-shape.patch +++ b/patches/server/0064-lithium-shape.patch @@ -270,10 +270,10 @@ index b95115aca72ba0cf6451096ddbd8b50a8f3bb5c6..0afb8c643cb3e5938e12183c6132797d int j = i - 1; diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java -index 2ed54208faf35ea5b4ea8540e95886b56d4d11fe..4b64a8f7ca507a54871c3b4929e663a60897870d 100644 +index 75c9d10e05a88d56c1d7800cd4da081cd5c86ff1..f0bda99478c53a1fbe413ffbae21dc7da0456ead 100644 --- a/src/main/java/net/minecraft/world/entity/Entity.java +++ b/src/main/java/net/minecraft/world/entity/Entity.java -@@ -2676,6 +2676,7 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, ne +@@ -2709,6 +2709,7 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, ne return this.isSneaking(); } diff --git a/patches/server/0065-lithium-skip-ticking-block-entities-that-are-doing-n.patch b/patches/server/0065-lithium-skip-ticking-block-entities-that-are-doing-n.patch index 3510429a..9017bcc5 100644 --- a/patches/server/0065-lithium-skip-ticking-block-entities-that-are-doing-n.patch +++ b/patches/server/0065-lithium-skip-ticking-block-entities-that-are-doing-n.patch @@ -797,10 +797,10 @@ index 95479df9fb009c5ca1872f8ee89b13e9c66d0bb6..52243bce89b28572efae9af54348502f NBTTagList nbttaglist = nbttagcompound.getList("Bees", 10); diff --git a/src/main/java/net/minecraft/world/level/block/entity/TileEntityBell.java b/src/main/java/net/minecraft/world/level/block/entity/TileEntityBell.java -index 84f9f52c5b632621b509448ac1c760f64de6b062..c4c983b15c28db856be7335e53637a21af2c1b2f 100644 +index 83626417aa9a00096680851a9a14f52f84fc7887..9f37518ada98c8ce64d283b49a9e3a7b6ec9457f 100644 --- a/src/main/java/net/minecraft/world/level/block/entity/TileEntityBell.java +++ b/src/main/java/net/minecraft/world/level/block/entity/TileEntityBell.java -@@ -20,6 +20,7 @@ import net.minecraft.world.entity.player.EntityHuman; +@@ -21,6 +21,7 @@ import net.minecraft.world.entity.player.EntityHuman; import net.minecraft.world.level.World; import net.minecraft.world.phys.AxisAlignedBB; import org.apache.commons.lang3.mutable.MutableInt; @@ -808,7 +808,7 @@ index 84f9f52c5b632621b509448ac1c760f64de6b062..c4c983b15c28db856be7335e53637a21 public class TileEntityBell extends TileEntity implements ITickable { -@@ -30,6 +31,8 @@ public class TileEntityBell extends TileEntity implements ITickable { +@@ -31,6 +32,8 @@ public class TileEntityBell extends TileEntity implements ITickable { private List h; private List getEntitiesAtRing() { return this.h; } // Paper - OBFHELPER private boolean i; private boolean getShouldReveal() { return this.i; } // Paper - OBFHELPER private int j; @@ -817,7 +817,7 @@ index 84f9f52c5b632621b509448ac1c760f64de6b062..c4c983b15c28db856be7335e53637a21 public TileEntityBell() { super(TileEntityTypes.BELL); -@@ -37,6 +40,11 @@ public class TileEntityBell extends TileEntity implements ITickable { +@@ -38,6 +41,11 @@ public class TileEntityBell extends TileEntity implements ITickable { @Override public boolean setProperty(int i, int j) { @@ -829,7 +829,7 @@ index 84f9f52c5b632621b509448ac1c760f64de6b062..c4c983b15c28db856be7335e53637a21 if (i == 1) { this.f(); this.j = 0; -@@ -81,6 +89,11 @@ public class TileEntityBell extends TileEntity implements ITickable { +@@ -82,6 +90,11 @@ public class TileEntityBell extends TileEntity implements ITickable { } } @@ -841,7 +841,7 @@ index 84f9f52c5b632621b509448ac1c760f64de6b062..c4c983b15c28db856be7335e53637a21 } private void d() { -@@ -88,6 +101,11 @@ public class TileEntityBell extends TileEntity implements ITickable { +@@ -89,6 +102,11 @@ public class TileEntityBell extends TileEntity implements ITickable { } public void a(EnumDirection enumdirection) { @@ -1000,7 +1000,7 @@ index 08759f461ec947c0d5655557f49d8717afee6f00..cdff01d4da417ef1be6238d3faaf464e ContainerUtil.b(nbttagcompound, this.items); int[] aint; diff --git a/src/main/java/net/minecraft/world/level/block/entity/TileEntityChest.java b/src/main/java/net/minecraft/world/level/block/entity/TileEntityChest.java -index cfabc9047cd3e972af84700725355d0fe149b221..4f5f050a947cd708ab375565192fde03ba79d7c4 100644 +index 324b752c70e0bd7ea06caa98ec15cdd4e6ea40ae..ebc4385e648e6205b1b6893e818b302a66f1cfea 100644 --- a/src/main/java/net/minecraft/world/level/block/entity/TileEntityChest.java +++ b/src/main/java/net/minecraft/world/level/block/entity/TileEntityChest.java @@ -33,14 +33,27 @@ import net.minecraft.world.level.block.Blocks; @@ -1031,7 +1031,7 @@ index cfabc9047cd3e972af84700725355d0fe149b221..4f5f050a947cd708ab375565192fde03 // CraftBukkit start - add fields and methods public List transaction = new java.util.ArrayList(); -@@ -135,11 +148,27 @@ public class TileEntityChest extends TileEntityLootable { // Paper - Remove ITic +@@ -137,11 +150,27 @@ public class TileEntityChest extends TileEntityLootable { // Paper - Remove ITic } public void tick() { @@ -1059,7 +1059,7 @@ index cfabc9047cd3e972af84700725355d0fe149b221..4f5f050a947cd708ab375565192fde03 } public void doOpenLogic() { -@@ -245,6 +274,7 @@ public class TileEntityChest extends TileEntityLootable { // Paper - Remove ITic +@@ -247,6 +276,7 @@ public class TileEntityChest extends TileEntityLootable { // Paper - Remove ITic @Override public boolean setProperty(int i, int j) { @@ -1067,7 +1067,7 @@ index cfabc9047cd3e972af84700725355d0fe149b221..4f5f050a947cd708ab375565192fde03 if (i == 1) { this.viewingCount = j; return true; -@@ -276,7 +306,7 @@ public class TileEntityChest extends TileEntityLootable { // Paper - Remove ITic +@@ -278,7 +308,7 @@ public class TileEntityChest extends TileEntityLootable { // Paper - Remove ITic // CraftBukkit end this.onOpen(); } @@ -1076,7 +1076,7 @@ index cfabc9047cd3e972af84700725355d0fe149b221..4f5f050a947cd708ab375565192fde03 } @Override -@@ -297,6 +327,7 @@ public class TileEntityChest extends TileEntityLootable { // Paper - Remove ITic +@@ -299,6 +329,7 @@ public class TileEntityChest extends TileEntityLootable { // Paper - Remove ITic // CraftBukkit end this.onOpen(); } diff --git a/upstream/Airplane b/upstream/Airplane index 636dbff0..3e07ea8c 160000 --- a/upstream/Airplane +++ b/upstream/Airplane @@ -1 +1 @@ -Subproject commit 636dbff0fb95c8023821e658e0ab01a74cf5d9d0 +Subproject commit 3e07ea8cf6f3739eac4710f914222f952fbce43b diff --git a/upstream/Empirecraft b/upstream/Empirecraft index 12009c31..105217a9 160000 --- a/upstream/Empirecraft +++ b/upstream/Empirecraft @@ -1 +1 @@ -Subproject commit 12009c3181bca30b97aabf4efbc78e64db2a46ae +Subproject commit 105217a96305f2e400a871ddad5a383b4973706a diff --git a/upstream/Origami b/upstream/Origami index 64fba4f7..d0cdf967 160000 --- a/upstream/Origami +++ b/upstream/Origami @@ -1 +1 @@ -Subproject commit 64fba4f73c65c2974f39d4ea3fdbc20bc00e2779 +Subproject commit d0cdf967180ef028c9ba7a8c5b9f5239588892fb diff --git a/upstream/Purpur b/upstream/Purpur index 687936be..d2204a3d 160000 --- a/upstream/Purpur +++ b/upstream/Purpur @@ -1 +1 @@ -Subproject commit 687936be57894f5fa37980c9af270dc3c4eff9ba +Subproject commit d2204a3daca80a3a3da068215e3fa530bb0620b9 diff --git a/upstream/Tuinity b/upstream/Tuinity index e9c83482..f7c42491 160000 --- a/upstream/Tuinity +++ b/upstream/Tuinity @@ -1 +1 @@ -Subproject commit e9c834821c6dee750fd0b9e87bc67456ba45555f +Subproject commit f7c42491a092c2dbd2d4736dd9713dc29c0bc099 diff --git a/upstreamCommits/Airplane b/upstreamCommits/Airplane index 5595a56b..32815018 100644 --- a/upstreamCommits/Airplane +++ b/upstreamCommits/Airplane @@ -1 +1 @@ -636dbff0fb95c8023821e658e0ab01a74cf5d9d0 \ No newline at end of file +3e07ea8cf6f3739eac4710f914222f952fbce43b \ No newline at end of file diff --git a/upstreamCommits/Empirecraft b/upstreamCommits/Empirecraft index 26a297e7..5fe882e2 100644 --- a/upstreamCommits/Empirecraft +++ b/upstreamCommits/Empirecraft @@ -1 +1 @@ -12009c3181bca30b97aabf4efbc78e64db2a46ae \ No newline at end of file +105217a96305f2e400a871ddad5a383b4973706a \ No newline at end of file diff --git a/upstreamCommits/Origami b/upstreamCommits/Origami index 5e9fc01e..2971b97e 100644 --- a/upstreamCommits/Origami +++ b/upstreamCommits/Origami @@ -1 +1 @@ -64fba4f73c65c2974f39d4ea3fdbc20bc00e2779 \ No newline at end of file +d0cdf967180ef028c9ba7a8c5b9f5239588892fb \ No newline at end of file diff --git a/upstreamCommits/Purpur b/upstreamCommits/Purpur index 637b0000..d936002b 100644 --- a/upstreamCommits/Purpur +++ b/upstreamCommits/Purpur @@ -1 +1 @@ -687936be57894f5fa37980c9af270dc3c4eff9ba \ No newline at end of file +d2204a3daca80a3a3da068215e3fa530bb0620b9 \ No newline at end of file diff --git a/upstreamCommits/Tuinity b/upstreamCommits/Tuinity index b9530802..15a5f076 100644 --- a/upstreamCommits/Tuinity +++ b/upstreamCommits/Tuinity @@ -1 +1 @@ -e9c834821c6dee750fd0b9e87bc67456ba45555f \ No newline at end of file +f7c42491a092c2dbd2d4736dd9713dc29c0bc099 \ No newline at end of file