- تم التحرير
Hold Previous question
Hey Harald sorry for all the questions recently, lol
I noticed something unexpected with using Hold Previous on animations - I made a little repro project to show it. Not sure if its a bug or my misunderstanding.
Unity Project: https://drive.google.com/file/d/14QnEceYzguvB2ugDmBIzBxhTZKdO6NX6/view?usp=sharing
Spine Project: https://drive.google.com/file/d/1jdejTR-NOEgfhfXpQnUmFnJzHN0BKid6/view?usp=sharing
The Setup Pose for the spine project has the bone pointing downward. There are 2 animations, one that has the bone pointing straight up, and one that has the bone pointing up-right.
In the Unity project, if you press the Right-Arrow key, it sets the animation on track 1 to the up-right one, and sets HoldPrevious to true for the Track Entry.
If you press the Left-Arrow key, it sets the animation on track 1 to the straight-up one, and sets HoldPrevious to true for the Track Entry.
Things work as expected if you press the right-arrow and left-arrow keys slowly, but if you press them really quickly back and forth (like spamming the buttons quick), the bone dips down towards the Setup Pose.
If you turn off HoldPrevious the dipping doesn't happen :think:
Thanks for reporting with the fully repro project! We're having a look at it and will get back to you as soon as we've figured out what's going wrong.
Thanks to your reproduction asset we could boil the problem down to the following code reproducing the problem as well:
state.setAnimation(0, "straight up", true);
TrackEntry entry = state.setAnimation(1, "straight up", false);
entry.mixDuration = 0.5f;
entry = state.addAnimation(1, "straight up", false, 0.5f);
entry.holdPrevious = true;
entry.mixDuration = 0.5f;
entry = state.addAnimation(1, "straight up", false, 0.01f);
entry.holdPrevious = true;
entry.mixDuration = 0.5f;
I just filed an issue ticket here:
[runtimes] Hold previous on 3+ animations causes dipping · #1738
We will let you know once we have come up with a bugfix.
A bugfix has just been committed, a new 3.8 spine-unity unitypackage is available for download here as usual:
Spine Unity Download
Thanks for reporting!
Harald wroteA bugfix has just been committed, a new 3.8 spine-unity unitypackage is available for download here as usual:
Spine Unity DownloadThanks for reporting!
Awesome! Thanks a lot Harald!
Strangely for some reason I didn't get a notification email for your responses (only the initial response) :think:
You're welcome!
Jamez0r wroteStrangely for some reason I didn't get a notification email for your responses (only the initial response)
Sorry to hear, that's a bit unfortunate. Did you subscribe to the thread explicitly, or was that done automatically since you started it? Admittedly I'm not too well informed about notification behaviour on the forum, as we check all new messages every day anyway.
Harald wroteYou're welcome!
Jamez0r wroteStrangely for some reason I didn't get a notification email for your responses (only the initial response)
Sorry to hear, that's a bit unfortunate. Did you subscribe to the thread explicitly, or was that done automatically since you started it? Admittedly I'm not too well informed about notification behaviour on the forum, as we check all new messages every day anyway.
Hmm, yeah I think that by default I get email notifications when anyone replies to the post, but maybe don't get multiple emails if the same person replies multiple times? Like how it combines the responses and adds the "
" separator :think:
Good point, that could indeed be the problem. Unfortunately I know of no way to prevent the posting from being joined automatically. :wounded: