Also fix draining while sneaking on ground for the Wingpack

dev
Arona Jones 2016-01-23 14:33:35 +00:00
parent 1af56fdf0d
commit 924d6cd758
2 changed files with 3 additions and 3 deletions

View File

@ -36,7 +36,7 @@ import steamcraft.common.lib.ModInfo;
*/
public class ItemClockworkWings extends BaseArmor
{
private static final float hungerPerTick = 1F;
private static final float hungerPerTick = 100F;
public ItemClockworkWings(ArmorMaterial mat, int renderIndex, int type)
{
@ -85,7 +85,7 @@ public class ItemClockworkWings extends BaseArmor
player.motionY += 0.4D;
}
if ((player.motionY < 0.0D) && player.isSneaking() && player.isAirBorne)
if ((player.motionY < 0.0D) && player.isSneaking() && !player.onGround)
{
player.addExhaustion(hungerPerTick / 6);
player.motionY /= 1.4D;

View File

@ -92,7 +92,7 @@ public class ItemSteamJetpack extends BaseArmor
}
if ((this == InitItems.itemSteamWingpack) && (player.motionY < 0.0D) && player.isSneaking())
if ((this == InitItems.itemSteamWingpack) && (player.motionY < 0.0D) && player.isSneaking() && !player.onGround)
{
this.consumeSteamFromCanister(player, (byte) (this.steamPerTick / 2));
player.motionY /= 1.4D;