diff --git a/nms-patches/EntityAnimal.patch b/nms-patches/EntityAnimal.patch index a095cddf81..c89ce6e214 100644 --- a/nms-patches/EntityAnimal.patch +++ b/nms-patches/EntityAnimal.patch @@ -1,9 +1,11 @@ --- a/net/minecraft/server/EntityAnimal.java +++ b/net/minecraft/server/EntityAnimal.java -@@ -8,6 +8,7 @@ +@@ -7,7 +7,8 @@ + protected Block bF; private int bC; - private UUID bD; +- private UUID bD; ++ public UUID bD; // PAIL + public ItemStack breedItem; // CraftBukkit - Add breedItem variable protected EntityAnimal(EntityTypes entitytypes, World world) { diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftAnimals.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftAnimals.java index 4b9b078305..f671ad1238 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftAnimals.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftAnimals.java @@ -1,5 +1,6 @@ package org.bukkit.craftbukkit.entity; +import java.util.UUID; import net.minecraft.server.EntityAnimal; import org.bukkit.craftbukkit.CraftServer; import org.bukkit.entity.Animals; @@ -19,4 +20,14 @@ public class CraftAnimals extends CraftAgeable implements Animals { public String toString() { return "CraftAnimals"; } + + @Override + public UUID getBreedCause() { + return getHandle().bD; + } + + @Override + public void setBreedCause(UUID uuid) { + getHandle().bD = uuid; + } }