From 24557bc2b37deb6a0edf497d547471832457b1dd Mon Sep 17 00:00:00 2001 From: Thinkofdeath Date: Wed, 26 Nov 2014 08:32:16 +1100 Subject: Update to Minecraft 1.8 For more information please see http://www.spigotmc.org/ --- nms-patches/MobSpawnerAbstract.patch | 38 ++++++++++++++++++++++++++++++++++++ 1 file changed, 38 insertions(+) create mode 100644 nms-patches/MobSpawnerAbstract.patch (limited to 'nms-patches/MobSpawnerAbstract.patch') diff --git a/nms-patches/MobSpawnerAbstract.patch b/nms-patches/MobSpawnerAbstract.patch new file mode 100644 index 00000000..1a936183 --- /dev/null +++ b/nms-patches/MobSpawnerAbstract.patch @@ -0,0 +1,38 @@ +--- ../work/decompile-bb26c12b/net/minecraft/server/MobSpawnerAbstract.java 2014-11-27 08:59:46.805421389 +1100 ++++ src/main/java/net/minecraft/server/MobSpawnerAbstract.java 2014-11-27 08:42:10.108850996 +1100 +@@ -4,6 +4,8 @@ + import java.util.Iterator; + import java.util.List; + ++import org.bukkit.event.entity.CreatureSpawnEvent; // CraftBukkit ++ + public abstract class MobSpawnerAbstract { + + public int spawnDelay = 20; +@@ -129,7 +131,7 @@ + + entity.f(nbttagcompound); + if (entity.world != null && flag) { +- entity.world.addEntity(entity); ++ entity.world.addEntity(entity, CreatureSpawnEvent.SpawnReason.SPAWNER); // CraftBukkit + } + + NBTTagCompound nbttagcompound1; +@@ -154,7 +156,7 @@ + entity2.f(nbttagcompound2); + entity2.setPositionRotation(entity1.locX, entity1.locY, entity1.locZ, entity1.yaw, entity1.pitch); + if (entity.world != null && flag) { +- entity.world.addEntity(entity2); ++ entity.world.addEntity(entity2, CreatureSpawnEvent.SpawnReason.SPAWNER); // CraftBukkit + } + + entity1.mount(entity2); +@@ -164,7 +166,7 @@ + } + } else if (entity instanceof EntityLiving && entity.world != null && flag) { + ((EntityInsentient) entity).prepare(entity.world.E(new BlockPosition(entity)), (GroupDataEntity) null); +- entity.world.addEntity(entity); ++ entity.world.addEntity(entity, CreatureSpawnEvent.SpawnReason.SPAWNER); // CraftBukkit + } + + return entity; -- cgit v1.2.3