- Edited
Does Spine support FixedUpdate in Unity?
I want to make the fighting game which need rigorous collision management like street fighter2 using Spine and Unity.
So in this case, Spine needs to support a fixedupdate function in the unity.
Does Spine support FixedUpdate() in Unity? Or, Does anyone know a better way?
Incidentally:
Another question, Can I preview Spine in Animation window?
(1) It can support it.
Here's where animation updates happen in standard Spine-Unity's SkeletonAnimation component: https://github.com/EsotericSoftware/spi ... ion.cs#L97
For your purposes, you could have a new class inherit from SkeletonAnimation and only have this in its body:
public override void Update () { }
void FixedUpdate () {
Update(Time.fixedDeltaTime);
}
The other option is just to modify SkeletonAnimation itself, remove its Update method and add this FixedUpdate method.
That'll make it work.
(2)
Select the SkeletonDataAsset (the file with the spine icon) in your assets/Project panel. Its inspector has a preview window.
Thanks a lot!
(1)
I have tried it.
However, I want you to officially support if possible...
Character (Spine) will not display in scene view if using this way. :sweat:
(2)
Sorry for not explaining enough. :whew:
I want to create animation and collision to Spine with preview in the Unity.
Because an animation which is created on the Spine is not work on the Unity. :sweat:
Hey! I will post a good reply to this tomorrow
Also Pharan and I did more work on bounding boxes tonight. I will post update tomorrow though.
Oyasumi!
Doing fixed update as suggested is the correct way. We don't need a setting for it.
Note Street Fighter uses relatively simple bounding boxes:
Image removed due to the lack of support for HTTPS. | Show Anyway
They are not all axis aligned, but most are. All the hit boxes seem to be. I'm not sure their bounding boxes are transformed by bones, even though SFIV is obviously skeletal animation, or if they manually position them for each frame at 60 fps.