From bcf979b2a6c35a4cef91b7966d87a350b23e300e Mon Sep 17 00:00:00 2001 From: EvilSeph Date: Thu, 1 Mar 2012 22:47:33 -0500 Subject: [PATCH] Fixed hunger not behaving correctly. Addresses BUKKIT-907 --- src/main/java/net/minecraft/server/FoodMetaData.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/main/java/net/minecraft/server/FoodMetaData.java b/src/main/java/net/minecraft/server/FoodMetaData.java index a659813a94..2b6b5845a9 100644 --- a/src/main/java/net/minecraft/server/FoodMetaData.java +++ b/src/main/java/net/minecraft/server/FoodMetaData.java @@ -33,7 +33,7 @@ public class FoodMetaData { this.saturationLevel = Math.max(this.saturationLevel - 1.0F, 0.0F); } else if (i > 0) { // CraftBukkit start - org.bukkit.event.entity.FoodLevelChangeEvent event = org.bukkit.craftbukkit.event.CraftEventFactory.callFoodLevelChangeEvent(entityhuman, Math.min(this.foodLevel - 1, 0)); + org.bukkit.event.entity.FoodLevelChangeEvent event = org.bukkit.craftbukkit.event.CraftEventFactory.callFoodLevelChangeEvent(entityhuman, Math.max(this.foodLevel - 1, 0)); if (!event.isCancelled()) { this.foodLevel = event.getFoodLevel();