-
LI WEI thinks this is interesting:
We can also do other things as we're reducing the player's hp, such as take into account the player's armor, check whether the player is invulnerable, or have other effects occur when the player is damaged. What happens when the player is damaged should be abstracted away by the damage() function.
Minimise