1
0
Fork 0
mirror of https://github.com/luanti-org/luanti.git synced 2025-08-11 17:51:04 +00:00

Fix local animations not resetting

Converts `LocalPlayerAnimation` to a scoped enum to prevent such bugs in the future
This commit is contained in:
Lars Müller 2023-07-02 12:47:18 +02:00 committed by GitHub
parent ff498fc206
commit 25ef8f3934
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 13 additions and 11 deletions

View file

@ -34,7 +34,7 @@ class ClientEnvironment;
class IGameDef;
struct collisionMoveResult;
enum LocalPlayerAnimations
enum class LocalPlayerAnimation
{
NO_ANIM,
WALK_ANIM,
@ -90,7 +90,7 @@ public:
bool makes_footstep_sound = true;
int last_animation = NO_ANIM;
LocalPlayerAnimation last_animation = LocalPlayerAnimation::NO_ANIM;
float last_animation_speed = 0.0f;
std::string hotbar_image = "";