diff options
author | booky10 <[email protected]> | 2023-11-04 20:20:01 +0100 |
---|---|---|
committer | GitHub <[email protected]> | 2023-11-04 20:20:01 +0100 |
commit | f78d7ce8ffb7e4b6fd5ee256f5e3678ea04fd807 (patch) | |
tree | 8e7abee5129e15a919630824c4f194a2811f7242 /patches/server/0874-Track-projectile-source-for-fireworks-from-dispenser.patch | |
parent | 44057da46727138e19d951b56e98ad8c25c1f869 (diff) | |
download | Paper-f78d7ce8ffb7e4b6fd5ee256f5e3678ea04fd807.tar.gz Paper-f78d7ce8ffb7e4b6fd5ee256f5e3678ea04fd807.zip |
Remove "fix-curing-zombie-villager-discount" exploit option (#9895)
Diffstat (limited to 'patches/server/0874-Track-projectile-source-for-fireworks-from-dispenser.patch')
-rw-r--r-- | patches/server/0874-Track-projectile-source-for-fireworks-from-dispenser.patch | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/patches/server/0874-Track-projectile-source-for-fireworks-from-dispenser.patch b/patches/server/0874-Track-projectile-source-for-fireworks-from-dispenser.patch new file mode 100644 index 0000000000..fe9f8e5826 --- /dev/null +++ b/patches/server/0874-Track-projectile-source-for-fireworks-from-dispenser.patch @@ -0,0 +1,18 @@ +From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001 +From: Jake Potrebic <[email protected]> +Date: Thu, 23 Jun 2022 19:25:51 -0700 +Subject: [PATCH] Track projectile source for fireworks from dispensers + + +diff --git a/src/main/java/net/minecraft/core/dispenser/DispenseItemBehavior.java b/src/main/java/net/minecraft/core/dispenser/DispenseItemBehavior.java +index e9db6b5096e7368b4a32a0e86eebccac15ab443b..f9ab6d4f6e7f430d41b79227e74136a3e980f340 100644 +--- a/src/main/java/net/minecraft/core/dispenser/DispenseItemBehavior.java ++++ b/src/main/java/net/minecraft/core/dispenser/DispenseItemBehavior.java +@@ -517,6 +517,7 @@ public interface DispenseItemBehavior { + itemstack1 = CraftItemStack.asNMSCopy(event.getItem()); + Vec3 vec3d = DispenseItemBehavior.getEntityPokingOutOfBlockPos(pointer, EntityType.FIREWORK_ROCKET, enumdirection); + FireworkRocketEntity entityfireworks = new FireworkRocketEntity(pointer.level(), itemstack1, vec3d.x(), vec3d.y(), vec3d.z(), true); // Paper - GH-2871 - fix last firework in stack having no effects when dispensed ++ entityfireworks.projectileSource = new org.bukkit.craftbukkit.projectiles.CraftBlockProjectileSource(pointer.blockEntity()); // Paper - track projectile source for fireworks + + entityfireworks.shoot((double) enumdirection.getStepX(), (double) enumdirection.getStepY(), (double) enumdirection.getStepZ(), 0.5F, 1.0F); + pointer.level().addFreshEntity(entityfireworks); |