forked from xjboss/KCauldronX
Initial commit (Forge 1291).
This commit is contained in:
17
patches/net/minecraft/entity/ai/EntityAIBreakDoor.java.patch
Normal file
17
patches/net/minecraft/entity/ai/EntityAIBreakDoor.java.patch
Normal file
@ -0,0 +1,17 @@
|
||||
--- ../src-base/minecraft/net/minecraft/entity/ai/EntityAIBreakDoor.java
|
||||
+++ ../src-work/minecraft/net/minecraft/entity/ai/EntityAIBreakDoor.java
|
||||
@@ -58,6 +58,14 @@
|
||||
|
||||
if (this.breakingTime == 240 && this.theEntity.worldObj.difficultySetting == EnumDifficulty.HARD)
|
||||
{
|
||||
+ // CraftBukkit start
|
||||
+ if (org.bukkit.craftbukkit.event.CraftEventFactory.callEntityBreakDoorEvent(this.theEntity, this.entityPosX, this.entityPosY, this.entityPosZ).isCancelled())
|
||||
+ {
|
||||
+ this.updateTask();
|
||||
+ return;
|
||||
+ }
|
||||
+
|
||||
+ // CraftBukkit end
|
||||
this.theEntity.worldObj.setBlockToAir(this.entityPosX, this.entityPosY, this.entityPosZ);
|
||||
this.theEntity.worldObj.playAuxSFX(1012, this.entityPosX, this.entityPosY, this.entityPosZ, 0);
|
||||
this.theEntity.worldObj.playAuxSFX(2001, this.entityPosX, this.entityPosY, this.entityPosZ, Block.getIdFromBlock(this.field_151504_e));
|
Reference in New Issue
Block a user