summaryrefslogtreecommitdiffstats
path: root/nms-patches/EntityZombieVillager.patch
diff options
context:
space:
mode:
Diffstat (limited to 'nms-patches/EntityZombieVillager.patch')
-rw-r--r--nms-patches/EntityZombieVillager.patch15
1 files changed, 12 insertions, 3 deletions
diff --git a/nms-patches/EntityZombieVillager.patch b/nms-patches/EntityZombieVillager.patch
index 895bf789..be60d420 100644
--- a/nms-patches/EntityZombieVillager.patch
+++ b/nms-patches/EntityZombieVillager.patch
@@ -47,7 +47,15 @@
this.world.broadcastEntityEffect(this, (byte) 16);
}
-@@ -123,7 +135,12 @@
+@@ -116,14 +128,20 @@
+ entityvillager.setAgeRaw(-24000);
+ }
+
+- this.world.kill(this);
++ // this.world.kill(this); // CraftBukkit - moved down
+ entityvillager.setNoAI(this.isNoAI());
+ if (this.hasCustomName()) {
+ entityvillager.setCustomName(this.getCustomName());
entityvillager.setCustomNameVisible(this.getCustomNameVisible());
}
@@ -56,12 +64,13 @@
+ if (CraftEventFactory.callEntityTransformEvent(this, entityvillager, EntityTransformEvent.TransformReason.CURED).isCancelled()) {
+ return;
+ }
-+ // CraftBukkit end
++ this.world.kill(this); // CraftBukkit - from above
+ this.world.addEntity(entityvillager, org.bukkit.event.entity.CreatureSpawnEvent.SpawnReason.CURED); // CraftBukkit - add SpawnReason
++ // CraftBukkit end
if (this.bD != null) {
EntityHuman entityhuman = this.world.b(this.bD);
-@@ -132,7 +149,7 @@
+@@ -132,7 +150,7 @@
}
}