Okay, so I have this simple RPG game that I want to make, but I’m having a bit of trouble figuring out how to code the character’s movements and idle animations in Playmaker.
In the Animator, I have all the BlendTree layers created (Idle, Walking, etc.) [so the Base Layer in the Animator window looks tidier] and they contain animations for each direction for my character (up, down, left and right), each of which are set with X and Y position parameters to correspond with each direction:
Up (0, 1), Down (0, -1), Left (-1, 0) and Right (1, 0). These are set for both the ‘Walking’ and ‘Idle’ BlendTrees.
Now how do I take these animations and code them into Playmaker?
What I want to do is, when I press a specific arrow key down, it should play the corresponding animation (from the BlendTree) while moving and when I release that arrow key, the player should stop in the idle animation that matches the direction the player was moving last.
Any help would be appreciated.