Skip to content
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

[spine-ts] Wrong Y-Position of Origin is Rendered #94

Open
vicksonzero opened this issue Jan 5, 2018 · 2 comments
Open

[spine-ts] Wrong Y-Position of Origin is Rendered #94

vicksonzero opened this issue Jan 5, 2018 · 2 comments

Comments

@vicksonzero
Copy link

vicksonzero commented Jan 5, 2018

I am using:

I made a strawberry sprite that sits in the center of the spine scene,
It uses deform animations
and then I load and create it in-game (at 0, 0)
I expect it to appear in the top-left corner, with only the lower-right corner visible.

but actually, the strawberry appear much lower, and the whole right-side is visible in the game.

I then made the following changes to the source and it correctly aligns to the origin again:
screenshot 488 cropped

may I know what the purpose is for the deleted piece of code?

Edit: i also removed var scale = Math.max(scale2.x, scale2.y); and used scale2.x and scale2.y as-is
why are the scale normalized like this?

Are the lines intended, or did I break something by fixing it?

@vicksonzero
Copy link
Author

Edit: i also removed var scale = Math.max(scale2.x, scale2.y); and used scale2.x and scale2.y as-is
why are the scale normalized like this?

@vicksonzero
Copy link
Author

Also found that
this.mvp.ortho2d(x * res, y, width * res, height * res);

doesn't have y * res written. is it also intentional?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant