13
0
geforkt von Mirrors/Paper
Paper/Spigot-Server-Patches/Move-ProjectileHitEvent-call-to-proper-place.patch
2016-11-21 22:24:19 -08:00

28 Zeilen
1.8 KiB
Diff

From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
From: AlphaBlend <whizkid3000@hotmail.com>
Date: Mon, 21 Nov 2016 22:21:53 -0800
Subject: [PATCH] Move ProjectileHitEvent call to proper place
diff --git a/src/main/java/net/minecraft/server/EntityFishingHook.java b/src/main/java/net/minecraft/server/EntityFishingHook.java
index 0000000000000000000000000000000000000000..0000000000000000000000000000000000000000 100644
--- a/src/main/java/net/minecraft/server/EntityFishingHook.java
+++ b/src/main/java/net/minecraft/server/EntityFishingHook.java
@@ -0,0 +0,0 @@ public class EntityFishingHook extends Entity {
// Paper end
if (movingobjectposition != null) {
- org.bukkit.craftbukkit.event.CraftEventFactory.callProjectileHitEvent(this, movingobjectposition.entity); // Craftbukkit - Call event // Paper - Include entity in movingobjectposition
+ //org.bukkit.craftbukkit.event.CraftEventFactory.callProjectileHitEvent(this, movingobjectposition.entity); // Craftbukkit - Call event // Paper - Wrong location, moved down to proper location
vec3d1 = new Vec3D(movingobjectposition.pos.x, movingobjectposition.pos.y, movingobjectposition.pos.z);
}
@@ -0,0 +0,0 @@ public class EntityFishingHook extends Entity {
if (movingobjectposition != null && movingobjectposition.type != MovingObjectPosition.EnumMovingObjectType.MISS) {
if (movingobjectposition.type == MovingObjectPosition.EnumMovingObjectType.ENTITY) {
+ org.bukkit.craftbukkit.event.CraftEventFactory.callProjectileHitEvent(this, movingobjectposition.entity); // Craftbukkit - Call event // Paper - Include entity in movingobjectposition
this.hooked = movingobjectposition.entity;
this.s();
} else {
--