Mecanim platformer side view animation states approach
I'm creating a game that has a similar camera as Spelunky (platformer, side view). As you can see in this gif (not fully on the side view) I have an idle, that changes to walk right and then from idle to walk left. All animations are in place loops because actual moving will be controlled elsewhere. The walk left is a mirror of walk right (copied and then root transform baked into pose of 180).
This works, however, as you see, when I transition back to idle from left things get weird. Depending on the timing it may rotate left or right. Also, since idle is by default facing right it will always come back to facing right from left (not what I want, and instead want it facing left when walk left is released).
Anyway, I then started thinking about having substates, all animations and transitions when facing left, and then copied sets and animations for facing right. Uggg, that will get messy. I'm sure there is a more elegant approach, does anyone have any ideas? Still new to mecanim myself.
Some solutions I'm thinking of....
simply change the transform.rotation of the characters parent to 180 and delete the walking left state.
Using Unity Pro and "Layer Syncing"
$$anonymous$$irror the left animation ins$$anonymous$$d of doing a root transform, see this gif capture, while it looks slick, it will create some issue with her raised hand and needing to unnecessarily swap whatever she is holding (fireballs etc). I do like that she is always facing the camera. Unfortunately, after keyup from left walk the idle bounces back to racing right in idle of course.