Merge pull request #1653 from howtonotwin/chordatafix

Fix #1588: chordata ring stops player from drowning with no mana.
This commit is contained in:
Jonathan Smith committed 2015-12-13 21:10:15 +00:00
commit 81b7ac4be4
1 file changed
+2 -1
@@ -58,7 +58,8 @@ public class ItemWaterRing extends ItemBauble implements IManaUsingItem {
if(player.getAir() <= 1 && player instanceof EntityPlayer) {
int mana = ManaItemHandler.requestMana(stack, (EntityPlayer) player, 300, true);
player.setAir(mana);
if(mana > 0) // If zero gets in the player has no air but won't drown.
player.setAir(mana);
}
} else onUnequipped(stack, player);
}