diff options
author | Travis Watkins <amaranth@ubuntu.com> | 2012-10-24 22:53:23 -0500 |
---|---|---|
committer | EvilSeph <evilseph@gmail.com> | 2012-10-27 22:19:03 -0400 |
commit | 60819c6693daf19dde68b04af38a4fee8c7da988 (patch) | |
tree | e7bd96a07f0e9d9f1f6b2721ddd1bb5dd71eaf48 /src/main/java/net/minecraft/server/PathfinderGoalBreakDoor.java | |
parent | b9a72531b6e2ccc84bd021bca421255a957d96f7 (diff) | |
download | craftbukkit-60819c6693daf19dde68b04af38a4fee8c7da988.tar craftbukkit-60819c6693daf19dde68b04af38a4fee8c7da988.tar.gz craftbukkit-60819c6693daf19dde68b04af38a4fee8c7da988.tar.lz craftbukkit-60819c6693daf19dde68b04af38a4fee8c7da988.tar.xz craftbukkit-60819c6693daf19dde68b04af38a4fee8c7da988.zip |
Update CraftBukkit to Minecraft 1.4(.2).
Diffstat (limited to 'src/main/java/net/minecraft/server/PathfinderGoalBreakDoor.java')
-rw-r--r-- | src/main/java/net/minecraft/server/PathfinderGoalBreakDoor.java | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/src/main/java/net/minecraft/server/PathfinderGoalBreakDoor.java b/src/main/java/net/minecraft/server/PathfinderGoalBreakDoor.java index b9620ecb..930f2cce 100644 --- a/src/main/java/net/minecraft/server/PathfinderGoalBreakDoor.java +++ b/src/main/java/net/minecraft/server/PathfinderGoalBreakDoor.java @@ -10,11 +10,11 @@ public class PathfinderGoalBreakDoor extends PathfinderGoalDoorInteract { } public boolean a() { - return !super.a() ? false : !this.e.a_(this.a.world, this.b, this.c, this.d); + return !super.a() ? false : (!this.a.world.getGameRules().getBoolean("mobGriefing") ? false : !this.e.a_(this.a.world, this.b, this.c, this.d)); } - public void e() { - super.e(); + public void c() { + super.c(); this.i = 0; } @@ -24,14 +24,14 @@ public class PathfinderGoalBreakDoor extends PathfinderGoalDoorInteract { return this.i <= 240 && !this.e.a_(this.a.world, this.b, this.c, this.d) && d0 < 4.0D; } - public void c() { - super.c(); - this.a.world.f(this.a.id, this.b, this.c, this.d, -1); - } - public void d() { super.d(); - if (this.a.au().nextInt(20) == 0) { + this.a.world.g(this.a.id, this.b, this.c, this.d, -1); + } + + public void e() { + super.e(); + if (this.a.aA().nextInt(20) == 0) { this.a.world.triggerEffect(1010, this.b, this.c, this.d, 0); } @@ -39,7 +39,7 @@ public class PathfinderGoalBreakDoor extends PathfinderGoalDoorInteract { int i = (int) ((float) this.i / 240.0F * 10.0F); if (i != this.j) { - this.a.world.f(this.a.id, this.b, this.c, this.d, i); + this.a.world.g(this.a.id, this.b, this.c, this.d, i); this.j = i; } |