- 已编辑
Can spine flip skeleton and images?
When making an animation sometimes one needs to have an animation fliped on x/y axis. For example walking left and riight requires that same animation but flipped. Does Spine support skeleton and image flipping?
Yes, you can flip the skeleton in code by using appropriate flipX or flipY functions on the skeleton object.
Jap :Yes, you can flip the skeleton in code by using appropriate flipX or flipY functions on the skeleton object.
Can I flip it in the spine editor? I want to actually see it in the editor because I might do some image slot change based on the movement that is different from the origianal one.
No, you currently can't flip in the editor.
Nate :No, you currently can't flip in the editor.
Will spine support this in the future?
Yes, eventually.
Sorry, but is there any more information about this feature? Does it have any priority currently, or whether it is planned to be released by christmas or sometime next year?
For game animation cycles this may not be a useful feature, but there's been many times when I needed it when animating characters on a fighting game, and currently (hence this post). Animating characters in general requires me to flip them from side to side and this feature would help greatly. :nod: Additionally the IK targest seem to work funky. :drunk:
Or otherwise does anybody have a suggestion on how to go about it currently? What's the best way to go about it? Thanks
Err... what runtime are you using? The spine runtimes have a skeleton.FlipX and FlipY property that is very easy to use.
I'm not doing that at runtime, I need to do it whilst animating a character in Spine. For example, making a character turn around in an animation sequence.
Usually what I do in such cases now, I create TSR keyframes for every bone and controller in a frame, and then create TSR keyframes for every bone and controller in the next, but with -1 scale. I change the former keyframes interpolation to stepped. And then there's loads of work of making it look like turning around
However, I did come up with an easier way to go about it! I duplicate the attached images, and set their local scale to -1. Then they have to be moved and rotated into place. When I need to flip the character's body parts, I just activate the duplicate image. Might be a good, practical solution.
I'd like to get to it very soon, especially since it isn't terribly hard to do. I already wrote the timelines for it, just need to add the JSON and parsing, port the timelines to all runtimes, and add the UI in Spine.
A FlipX Timeline. Intriguing.
Can someone explain why scaling the root bone from 1;1 to -1;1 messes up the positions and rotations of all the children bones? Why doesn't it just... "FlipX"?
The forum has a lot of information, please use the search.
viewtopic.php?p=7456#p7456
2.0.18 is now up, has keyable flip x/y. spine-libgdx, spine-csharp, and spine-c have been updated. spine-as3 will be updated today. Select the skeleton in the tree to flip it.
- 已编辑
Woo! I never thought I'd live to see this day.
There has to be a way to move these miscellaneous timelines (event, draworder, flip) to the top of the dopesheet from the bottom.
Pharan :Woo! I never thought I'd live to see this day.
I updated the spine-unity.unitypackage too
I just read the code in the Animation class.
Wouldn't this break the code that's making your character logically face left or right? 'cause if the character was flipped to begin with, the values it would need to apply should be the opposite. I originally imagined a second flip value that would be XORed with skeleton.flipX
Nate :2.0.18 is now up, has keyable flip x/y
Thank you so much :yes:
Pharan :Woo! I never thought I'd live to see this day.
That's what you get for not giving your input all this time!
2.0.19 changes flip timelines. The skeleton can no longer be flipped in the editor, but any bone can be flipped. This flipping uses the world axes, not the bone's local axes, because it simplifies the work/math that needs to be done to update the world transform for bones.
Nate, flip is awesome! runtime support this?