diff options
author | Nassim Jahnke <[email protected]> | 2024-11-28 11:38:18 +0100 |
---|---|---|
committer | Nassim Jahnke <[email protected]> | 2024-11-29 10:52:17 +0100 |
commit | 71b5b9894ddbd7a9486f0cd8457af9c5ccdbe792 (patch) | |
tree | 28ffdb57a00ff12f2aa1155ed8cd72cdc781319b /patches/server/1072-Call-ProjectileHitEvent-for-entity-hits.patch | |
parent | 031ca6dcff86845d0d13524f5a9e1d0c3a7f9841 (diff) | |
download | Paper-71b5b9894ddbd7a9486f0cd8457af9c5ccdbe792.tar.gz Paper-71b5b9894ddbd7a9486f0cd8457af9c5ccdbe792.zip |
Move patch back a bitpool-nonsense
Diffstat (limited to 'patches/server/1072-Call-ProjectileHitEvent-for-entity-hits.patch')
-rw-r--r-- | patches/server/1072-Call-ProjectileHitEvent-for-entity-hits.patch | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/patches/server/1072-Call-ProjectileHitEvent-for-entity-hits.patch b/patches/server/1072-Call-ProjectileHitEvent-for-entity-hits.patch new file mode 100644 index 0000000000..7d6bd931cb --- /dev/null +++ b/patches/server/1072-Call-ProjectileHitEvent-for-entity-hits.patch @@ -0,0 +1,22 @@ +From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001 +From: Bjarne Koll <[email protected]> +Date: Sat, 23 Nov 2024 22:48:26 +0100 +Subject: [PATCH] Call ProjectileHitEvent for entity hits + +A simple bugfix replacing a new vanilla call to +Projectile#hitTargetOrDeflectSelf with the bukkit replacement to call +the event. + +diff --git a/src/main/java/net/minecraft/world/entity/projectile/AbstractArrow.java b/src/main/java/net/minecraft/world/entity/projectile/AbstractArrow.java +index accc246f441c8bf5e1a755cfc0db8f97c0c01c6b..571f0699772eecbe02d71845da82a142321f2142 100644 +--- a/src/main/java/net/minecraft/world/entity/projectile/AbstractArrow.java ++++ b/src/main/java/net/minecraft/world/entity/projectile/AbstractArrow.java +@@ -309,7 +309,7 @@ public abstract class AbstractArrow extends Projectile { + continue; + } + +- ProjectileDeflection projectiledeflection = this.hitTargetOrDeflectSelf(movingobjectpositionentity); ++ ProjectileDeflection projectiledeflection = this.preHitTargetOrDeflectSelf(movingobjectpositionentity); // Paper - also call projectile hit event + + this.hasImpulse = true; + if (this.getPierceLevel() > 0 && projectiledeflection == ProjectileDeflection.NONE) { |