fix autoeat kick when hungry in gui
This commit is contained in:
parent
e910229940
commit
f7da34738c
1 changed files with 2 additions and 1 deletions
|
@ -66,7 +66,8 @@ public class AutoEat extends Feature {
|
|||
|
||||
|
||||
private boolean isValid(ItemStack stack, int food) {
|
||||
return stack.getItem() instanceof ItemFood
|
||||
return mc.currentScreen != null && //fix
|
||||
stack.getItem() instanceof ItemFood
|
||||
&& !(stack.getItem() instanceof ItemChorusFruit)
|
||||
&& ((20 - food)>=((ItemFood) stack.getItem()).getHealAmount(stack)
|
||||
|| (stack.getItem() instanceof ItemAppleGold && mc.player.getHealth() < 19D)
|
||||
|
|
Loading…
Add table
Reference in a new issue