- Modifié
Unity - Merging New SPINE animations to old SkeletonData
Hi,
I have a weird predicament.
In the past I imported a set of SPINE animations into UNITY and created the skeletonData and animator controllers. It's working great.
I've now created an additional set of animations in Spine. But I exported it as a separated .Json\ .Atlas file into UNITY.
Is there a way to merge BOTH animations into one animator controller? I'm not having much luck at the moment.
this is the console error message
KeyNotFoundException: The given key was not present in the dictionary.
System.Collections.Generic.Dictionary`2[System.Int32,Spine.Animation].get_Item (Int32 key) (at /Users/builduser/buildslave/mono-runtime-and-classlibs/build/mcs/class/corlib/System.Collections.Generic/Dictionary.cs:150)
Spine.Unity.SkeletonAnimator.Update () (at Assets/spine-unity/SkeletonAnimator.cs:111)
No, one skeleton from Spine is one json.
And one json is one skeletonData. As long as they're separate jsons, they'll always be separate.
You need to do the merge in Spine editor.
Hi Pharan,
Sorry bringing up old thread here.
At the moment I'm thinking I have to redo my entire SPINE export into UNITY and redo my entire animator controller state setup.
I'm wondering if you can suggest a better workflow for me. For the future.
[Scenario]
I made 5 sets of simple animations with only key poses. I hooked them up in UNITY animator controller and set the states together. Focus was on code and design to make sure gameplay works. Animation polish was to come later in the pipeline.
I needed more animations for gameplay testing, so I created 2 more animations. I used the SAME SPINE file that contained the original 5 animations. I exported everything again.
The animator controller contained both old(5) and new(2) animations in UNITY. UNITY complained that the 2 separate SPINE animations weren't using the same keys. "KeyNotFoundException: The given key was not present in the dictionary." It still somehow worked, but I'm sure it's an incorrect thing I've done. :drunk: :drunk: :drunk:
[Questions]
In the future when I work on the final animations pass, for the game. Is there a way for me to keep intact my animator controller setup in UNITY while adding the new sets of animations? (This part took alot of time to fine tune and setup. It'd stink to have to redo it all)
Is there a more iterative approach I could take, for my SPINE animations to fit into a typical game production pipeline? (Preprod ~> production ~> alpha content ~> beta polish ~> gold) :sweat:
I'm still learning my way around SPINE, so perhaps I missed a critical workflow.
Hope the explanation has been clear.
Thanks again for all the support! :handshake: :handshake: