diff options
author | Thinkofdeath <thinkofdeath@spigotmc.org> | 2014-11-26 08:32:16 +1100 |
---|---|---|
committer | md_5 <git@md-5.net> | 2014-11-28 17:16:30 +1100 |
commit | 24557bc2b37deb6a0edf497d547471832457b1dd (patch) | |
tree | c560572889a3b0b34964a0cddb35dc87fda3c914 /src/main/java/net/minecraft/server/PathfinderGoalBreakDoor.java | |
parent | a4805dbd77da057cc1ea0bf344379bc6e53ca1f6 (diff) | |
download | craftbukkit-24557bc2b37deb6a0edf497d547471832457b1dd.tar craftbukkit-24557bc2b37deb6a0edf497d547471832457b1dd.tar.gz craftbukkit-24557bc2b37deb6a0edf497d547471832457b1dd.tar.lz craftbukkit-24557bc2b37deb6a0edf497d547471832457b1dd.tar.xz craftbukkit-24557bc2b37deb6a0edf497d547471832457b1dd.zip |
Update to Minecraft 1.8
For more information please see http://www.spigotmc.org/
Diffstat (limited to 'src/main/java/net/minecraft/server/PathfinderGoalBreakDoor.java')
-rw-r--r-- | src/main/java/net/minecraft/server/PathfinderGoalBreakDoor.java | 59 |
1 files changed, 0 insertions, 59 deletions
diff --git a/src/main/java/net/minecraft/server/PathfinderGoalBreakDoor.java b/src/main/java/net/minecraft/server/PathfinderGoalBreakDoor.java deleted file mode 100644 index 727f5f0c..00000000 --- a/src/main/java/net/minecraft/server/PathfinderGoalBreakDoor.java +++ /dev/null @@ -1,59 +0,0 @@ -package net.minecraft.server; - -public class PathfinderGoalBreakDoor extends PathfinderGoalDoorInteract { - - private int i; - private int j = -1; - - public PathfinderGoalBreakDoor(EntityInsentient entityinsentient) { - super(entityinsentient); - } - - public boolean a() { - return !super.a() ? false : (!this.a.world.getGameRules().getBoolean("mobGriefing") ? false : !this.e.f((IBlockAccess) this.a.world, this.b, this.c, this.d)); // CraftBukkit - Fix decompilation issue by casting world to IBlockAccess - } - - public void c() { - super.c(); - this.i = 0; - } - - public boolean b() { - double d0 = this.a.e((double) this.b, (double) this.c, (double) this.d); - - return this.i <= 240 && !this.e.f((IBlockAccess) this.a.world, this.b, this.c, this.d) && d0 < 4.0D; // CraftBukkit - Fix decompilation issue by casting world to IBlockAccess - } - - public void d() { - super.d(); - this.a.world.d(this.a.getId(), this.b, this.c, this.d, -1); - } - - public void e() { - super.e(); - if (this.a.aI().nextInt(20) == 0) { - this.a.world.triggerEffect(1010, this.b, this.c, this.d, 0); - } - - ++this.i; - int i = (int) ((float) this.i / 240.0F * 10.0F); - - if (i != this.j) { - this.a.world.d(this.a.getId(), this.b, this.c, this.d, i); - this.j = i; - } - - if (this.i == 240 && this.a.world.difficulty == EnumDifficulty.HARD) { - // CraftBukkit start - if (org.bukkit.craftbukkit.event.CraftEventFactory.callEntityBreakDoorEvent(this.a, this.b, this.c, this.d).isCancelled()) { - this.c(); - return; - } - // CraftBukkit end - - this.a.world.setAir(this.b, this.c, this.d); - this.a.world.triggerEffect(1012, this.b, this.c, this.d, 0); - this.a.world.triggerEffect(2001, this.b, this.c, this.d, Block.getId(this.e)); - } - } -} |