editor icon indicating copy to clipboard operation
editor copied to clipboard

Make Exit Time of Anim State Graph 0 by default

Open albertvanveen opened this issue 3 years ago • 2 comments

Every time I add a new animation I wonder why it doesn't work, only to find out again that Exit Time is 1 by default. Maybe stupid of me to keep forgetting this, but I think a default of 1 is illogical. Many animations are used in a loop.

albertvanveen avatar Jun 29 '22 19:06 albertvanveen

Hi @albertvanveen

The exit time was originally set to 0 by default, however this was leading to confusion over why animations weren't playing when they had transitions attached to them (they were playing but the transitions were set up without any conditions blocking them and so the animation exited as soon as it was entered). We decided that by setting it to 1 by default, users would at least see the animation playing through before the transition occurs, giving them an idea of what is going on in the graph.

Ideally I'd like to reduce these issues by introducing some form of visual graph debugging to the AnimStateGraph editor.

ellthompson avatar Jul 07 '22 11:07 ellthompson

So basically the animation was started repeatedly causing the animation to stop playing? Would it be an idea to check in the background if this is already the active state and if so don't restart the state?

With the current situation, the same problems arise in a different way. I have already covered a number of forum topics where the Exit Time of 1 was the problem.

https://forum.playcanvas.com/t/anim-component-issue/24979/6 https://forum.playcanvas.com/t/interrupt-to-jumping-animation-at-any-time/25037/9 https://forum.playcanvas.com/t/solved-anim-not-changing-animation-via-setboolean/25263/2

albertvanveen avatar Jul 07 '22 15:07 albertvanveen

Done

yaustar avatar Dec 02 '22 12:12 yaustar