Enum use - animations don't play/no transition

Hi guys - for the sake of cleanliness and learning about Enum - I’m trying to use them in my project for changing player states animations right now. and for the life of me i can’t figure it out.
I’m not too great on the ANIM BP side of things but I’ve included an animation where the character should crouch but the only thing it does is update the speed of the character and he starts to walk really slow. it doesn’t transition to the animation itself.
Any help would be appreciated!

1 Like

First thing I notice is here :
You get the variable “Player States” from your character (which is the correct thing to do since the value is changed there) but then you set the exact variable still from the character. Logically it doesn’t do anything that’s why the anim isn’t updated.
You already have the variable and use it correctly in the anim graph. You just have to set this variable instead of the one from the character.

There are few things you can do to remove some nodes.
In the character BP, there is no need to set crouch speed via BP. You set the speed on the movement component, and it will change automatically when “Crouch” or “Uncrouch” are executed.

In the anim BP the cast on the update isn’t necessary since you already have the character ref. I guess you tried to cast directly because it was not working, but it was worth mentioning. You don’t need the “Is valid” node either. Simply right click on the “Char ref” which is plugged into and choose “Convert to validated get”.
Finally you should have less nodes, and the last set (the enum) is the one from anim BP (it has no blue input) :

Hope it can help


Thank you so much @Grot13 !! I really appreciate it!!!
I will make these changes and hopefully will be all good :slight_smile: