mirror of
https://github.com/PaperMC/Paper.git
synced 2025-01-01 17:01:56 +01:00
bbe32f42f0
A simple bugfix replacing a new vanilla call to Projectile#hitTargetOrDeflectSelf with the bukkit replacement to call the event.
22 lines
1.3 KiB
Diff
22 lines
1.3 KiB
Diff
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
|
From: Bjarne Koll <git@lynxplay.dev>
|
|
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 0000000000000000000000000000000000000000..0000000000000000000000000000000000000000 100644
|
|
--- a/src/main/java/net/minecraft/world/entity/projectile/AbstractArrow.java
|
|
+++ b/src/main/java/net/minecraft/world/entity/projectile/AbstractArrow.java
|
|
@@ -0,0 +0,0 @@ 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) {
|