Hello everyone,
I am just wondering what the upsides of writing the code for the animation into the set function of the health variable. In the lecture this requires an if statement to check if the health decreased.
When I put the animation code inside a take_damage function I don’t need the if statement.
Both work but what would be best practice and why?
Thanks.