Animation problem with sprite resolver.

Hello!

I am trying to animate my pixel art character using the sprite resolver, problem is the animation works correctly with 60 samples in the clip in play mode, but I want to only have 12 samples, I made everything by following the documentation and by taking a look at the sample “Flipbook animation swap” (this is basically what I want to achieve so i can make skins, so I can have multiple characters without remaking all the clips for each of them). Animation clip does work exactly how I want when I play it using the animation tab but messes up when I enter play mode. please checkout the gifs:

In editor: forkedseparatedrever
In play mode: wickeddelightfulharrierhawk

1 Like

That’s great, it looks like a correct setup for your case.
Did you change the keyframe tangent to Constant? Also make sure that other animation / scripts don’t override your Sprite Resolver values. If the issue still persists you can share your setup with me in a private message.

1 Like

Hey Marek, ̶Y̶e̶s̶ ̶I̶ ̶d̶i̶d̶ ̶c̶h̶a̶n̶g̶e̶ ̶t̶h̶e̶ ̶k̶e̶y̶f̶r̶a̶m̶e̶ ̶t̶a̶n̶g̶e̶n̶t̶ ̶t̶o̶ ̶c̶o̶n̶s̶t̶a̶n̶t̶,̶ ̶a̶n̶d̶ ̶I̶ ̶t̶e̶s̶t̶e̶d̶ ̶e̶v̶e̶r̶y̶t̶h̶i̶n̶g̶ ̶a̶g̶a̶i̶n̶ ̶w̶i̶t̶h̶o̶u̶t̶ ̶a̶n̶y̶ ̶s̶c̶r̶i̶p̶t̶s̶ ̶t̶o̶o̶ ̶t̶h̶e̶ ̶i̶s̶s̶u̶e̶ ̶i̶s̶ ̶s̶t̶i̶l̶l̶ ̶t̶h̶e̶r̶e̶ ̶I̶ ̶f̶e̶e̶l̶ ̶l̶i̶k̶e̶ ̶i̶t̶ ̶h̶a̶s̶ ̶s̶o̶m̶e̶t̶h̶i̶n̶g̶ ̶t̶o̶ ̶d̶o̶ ̶w̶i̶t̶h̶ ̶h̶o̶w̶ ̶i̶t̶ ̶i̶s̶ ̶r̶e̶n̶d̶e̶r̶i̶n̶g̶ ̶t̶h̶e̶ ̶a̶n̶i̶m̶a̶t̶i̶o̶n̶,̶ ̶I̶ ̶w̶i̶l̶l̶ ̶s̶e̶n̶d̶ ̶y̶o̶u̶ ̶t̶h̶e̶ ̶p̶r̶o̶j̶e̶c̶t̶/̶ ̶s̶c̶e̶n̶e̶.̶

Was writing you this reply then decided to create a new animator controller now it seems to work fine.

1 Like

Also just wondering if there is a faster way to add sprites into the sprite library asset? Kind of slower to put each sprite one by one.
@MarekUnity

I’m glad it’s working.

If you’re using 2D Animation 6.0 or higher (Unity 2021.1+) you should be able to populate categories by dragging and dropping single sprites or sprite sheet textures. Here is the documentation page describing it: Sprite Library Asset | 2D Animation | 6.0.7

@mmn_tlh I’m looking forward to getting some feedback on the Sprite Library Asset window and the drag & drop behavior. Feel free to share your thoughts on the tool and if you feel that some functionality is missing or you would like to see something improved and why.

Omg, this is a lifesaver, couldn’t figure this out after a long time, My animator kept sending me things that seemed to work in the animator screen, and when using them in playmode just simply wouldn’t work. Finally found this forum post, and magically all the animations are beautiful. Perhaps this should be more clear in the docs!

1 Like

Happy that you managed to resolve the issue, @AdamBebko and thanks for letting us know!
In Unity 2022.1 and onwards, you no longer need to update the keyframe tangent to Constant, the Sprite Resolver will just work with the Animation Window without any additional settings.

For Unity 2021.3 and older, we have a section in our 2D Animation docs which mentions this step, but it might be a bit difficult to find. Thank you for your feedback!

1 Like