HCRival/Atticus/Atticus-Server/nms-patches/PathfinderGoalTargetNearestPlayer.patch

12 lines
396 B
Diff
Raw Permalink Normal View History

--- a/net/minecraft/server/PathfinderGoalTargetNearestPlayer.java
+++ b/net/minecraft/server/PathfinderGoalTargetNearestPlayer.java
@@ -91,7 +91,7 @@
}
public void c() {
- this.b.setGoalTarget(this.e);
+ this.b.setGoalTarget(this.e, org.bukkit.event.entity.EntityTargetEvent.TargetReason.CLOSEST_PLAYER, true); // CraftBukkit - added reason
super.c();
}