We stop reducing stamina if players are idle and have lost most of
their available stamina. The stamina is reduced to a level where it
can't heal the player, but also doesn't hurt the player.
There no longer is a real stamina cap. Any food eaten while stamina
is not at the visual max(20) will have its stamina value added
entirely to the stamina value, exceeding the visual max, so
no food value is ever lost. However, you can't eat foods anymore
when the stamina value is at or over the visual cap.
- add exhaustion for punhing players
- fix exhaustion for craftin (was not working)
- add more exhaustion when jumping (double of walking)
I radically made the action callers simpler by pushing
all the validity checks down, which removes a bunch of
functions that were just duplicating code. This makes
much of it a lot more straightforward and easier to
understand.
This mod implements a reduced version of BlockMen's hunger+hud
mod, implementing a player "stamina" stat that converts food
hp_change to stamina points. Stamina points heal the player
over time if they are available and higher than the HP amount.