diff options
author | EvilSeph <evilseph@unaligned.org> | 2011-06-28 20:11:23 -0400 |
---|---|---|
committer | EvilSeph <evilseph@unaligned.org> | 2011-06-30 13:42:18 -0400 |
commit | 8a521ec629902255a56918d82bafb193ffa1ba54 (patch) | |
tree | f6ac244a091c3826b26d7ba72c122dd2794533b4 /src/main/java/net/minecraft/server/EntityHuman.java | |
parent | f518ced9adc7f2423e8bef4f3f2956709b934044 (diff) | |
download | craftbukkit-8a521ec629902255a56918d82bafb193ffa1ba54.tar craftbukkit-8a521ec629902255a56918d82bafb193ffa1ba54.tar.gz craftbukkit-8a521ec629902255a56918d82bafb193ffa1ba54.tar.lz craftbukkit-8a521ec629902255a56918d82bafb193ffa1ba54.tar.xz craftbukkit-8a521ec629902255a56918d82bafb193ffa1ba54.zip |
Added reasons for entities regaining health.
Diffstat (limited to 'src/main/java/net/minecraft/server/EntityHuman.java')
-rw-r--r-- | src/main/java/net/minecraft/server/EntityHuman.java | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/main/java/net/minecraft/server/EntityHuman.java b/src/main/java/net/minecraft/server/EntityHuman.java index 259eee24..f8e31db2 100644 --- a/src/main/java/net/minecraft/server/EntityHuman.java +++ b/src/main/java/net/minecraft/server/EntityHuman.java @@ -13,6 +13,7 @@ import org.bukkit.event.entity.EntityTargetEvent; import org.bukkit.event.player.PlayerBedEnterEvent; import org.bukkit.event.player.PlayerBedLeaveEvent; import org.bukkit.event.player.PlayerDropItemEvent; +import org.bukkit.event.entity.EntityRegainHealthEvent.RegainReason; // CraftBukkit end public abstract class EntityHuman extends EntityLiving { @@ -175,7 +176,7 @@ public abstract class EntityHuman extends EntityLiving { public void v() { // CraftBukkit - spawnMonsters -> allowMonsters if (!this.world.allowMonsters && this.health < 20 && this.ticksLived % 20 * 12 == 0) { - this.b(1); + this.b(1, RegainReason.REGEN); } this.inventory.f(); |