From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001 From: Jake Potrebic Date: Wed, 18 Nov 2020 11:32:46 -0800 Subject: [PATCH] Zombie API - breaking doors diff --git a/src/main/java/net/minecraft/server/EntityZombie.java b/src/main/java/net/minecraft/server/EntityZombie.java index 3e0b12fef4e0aa5bf8a9b905b829e2a305a53d12..88ccf77e0e124f64391f415a6e26d1187fade59e 100644 --- a/src/main/java/net/minecraft/server/EntityZombie.java +++ b/src/main/java/net/minecraft/server/EntityZombie.java @@ -78,10 +78,12 @@ public class EntityZombie extends EntityMonster { return (Boolean) this.getDataWatcher().get(EntityZombie.DROWN_CONVERTING); } + public boolean canBreakDoors() { return this.eU(); } // Paper - OBFHELPER public boolean eU() { return this.bs; } + public void setCanBreakDoors(boolean canBreakDoors) { this.u(canBreakDoors); } // Paper - OBFHELPER public void u(boolean flag) { if (this.eK() && PathfinderGoalUtil.a(this)) { if (this.bs != flag) { diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftZombie.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftZombie.java index d334e656ea0f442a14864a05d4701df162487851..7fc71fad484502ad0e9c6c6f6b32aaaf7599a6dd 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftZombie.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftZombie.java @@ -129,6 +129,16 @@ public class CraftZombie extends CraftMonster implements Zombie { public void setShouldBurnInDay(boolean shouldBurnInDay) { getHandle().setShouldBurnInDay(shouldBurnInDay); } + + @Override + public boolean canBreakDoors() { + return getHandle().canBreakDoors(); + } + + @Override + public void setCanBreakDoors(boolean canBreakDoors) { + getHandle().setCanBreakDoors(canBreakDoors); + } // Paper end @Override