You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
21 lines
847 B
21 lines
847 B
--- ../src-base/minecraft/net/minecraft/entity/passive/EntityOcelot.java |
|
+++ ../src-work/minecraft/net/minecraft/entity/passive/EntityOcelot.java |
|
@@ -89,7 +89,7 @@ |
|
|
|
protected boolean canDespawn() |
|
{ |
|
- return !this.isTamed() && this.ticksExisted > 2400; |
|
+ return !this.isTamed(); // CraftBukkit |
|
} |
|
|
|
public boolean isAIEnabled() |
|
@@ -188,7 +188,8 @@ |
|
|
|
if (!this.worldObj.isRemote) |
|
{ |
|
- if (this.rand.nextInt(3) == 0) |
|
+ // CraftBukkit - added event call and isCancelled check |
|
+ if (this.rand.nextInt(3) == 0 && !org.bukkit.craftbukkit.event.CraftEventFactory.callEntityTameEvent(this, p_70085_1_).isCancelled()) |
|
{ |
|
this.setTamed(true); |
|
this.setTameSkin(1 + this.worldObj.rand.nextInt(3));
|
|
|