One of the transition conditions in state machines is “Until x seconds left” and is very useful if you want to do an animation from a short event, e.g. jumping or clicking where the onpress event and the onrelease event happen ammediately, it ensures the jump or attack animation finishes before switching back to walk or idle.
However, I’m trying to blend a melee attack that is stationary with walking and running so the character doesn’t stop running when attacking. This obviously has to be done in a blendtree to get the blend nodes, and I’m using a pose mask to keep the leg movements but get the arm movements of the attack animation.
The problem is there is no “until x seconds left” for blend nodes, so simulating a click by ticking my “attack” checkbox parameter and then unticking it in quick succession leads to the animation starting for the attack but then immediately switching back to walking.
A thing worth noting is that between my move state machine and my attack state machine I’m using ful clip based sync mode to sync the legs so there is no problem there.