-
Notifications
You must be signed in to change notification settings - Fork 2.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[as3] TexturePacker Trim Settings Issues #948
Comments
FYI I was able to correct the issue with this ugly code. This certainly wouldn't run as quickly but perhaps it will help you find a better solution. Basically the problem was that when the texture is trimmed unevenly the pivot point is shifted away from 0,0...
|
That's actually a pretty good solution! It works for both the Spine and TexturePacker regions, including the Spine trimming. I wouldn't be concerned about performance to much, this method is only used when regions are loaded from JSON. I've merged this manually with some touch ups. Thanks! |
I've been playing with a Spine animation that runs the frame swapping for a sprite sheet animation. In Spine, the animation runs smoothly changing frames cleanly, but when run in AS3 code the image jumps along the X and Y axis on different frames. I've repackaged an example for you showcasing the issue. Meteor.spine contains one skeleton animation. I have provided two different TexturePacker projects to show why I believe the issue lies in the frame offset values. Meteor_texturePacker.tps exports an atlas that trims out empty alpha space from the frames of the animation, Meteor_texturePacker_noTrim.tps prevents this trimming leaving each image its original size. When you run the noTrim version the animation looks correct, when you run the trim version the meteor jumps as the frames change.
*Note that I apply a 0.25 scale to the skeletonJson when building the skeleton...
Meteor.zip
The text was updated successfully, but these errors were encountered: