Clean up jump exhaustion code a bit

This commit is contained in:
Wuzzy 2017-05-22 23:51:08 +02:00
parent ce3d3e06e9
commit 3cd02e3262
2 changed files with 19 additions and 13 deletions

View file

@ -267,17 +267,6 @@ minetest.register_globalstep(function(dtime)
end
end
local controls = player:get_player_control()
-- Determine if the player is moving
if controls.up or controls.down or controls.left or controls.right then
-- TODO: Add exhaustion for moving in water
end
-- Jumping
-- FIXME: This is quite hacky and doesn't check if the player is actually jumping
if controls.jump then
mcl_hunger.exhaust(name, mcl_hunger.EXHAUST_JUMP)
end
end
end
end