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

Weird value for contentBounds.yMax during sprite animation #41

Open
SatheeshJM opened this issue Mar 21, 2020 · 0 comments
Open

Weird value for contentBounds.yMax during sprite animation #41

SatheeshJM opened this issue Mar 21, 2020 · 0 comments

Comments

@SatheeshJM
Copy link

I have a sprite with multiple frames..
Whenever there is a frame change in the sprite, the value of sprite.contentBounds.yMax changes to a weird value during that frame.
In the next frame, it reverts back to the actual value

How to reproduce:

sprite_bounds_bug.zip
(have attached a plug-and-play project )

  1. Run project
  2. Monitor console logs.. When there is no frame change, yMax is ~630
  3. When there is a frame change, yMax changes to ~570 for a frame and in the next frame it reverts back to the old value.
    (see below for sample output)
23:05:22.260  frame : 1;yMax : 633.5	1
23:05:22.276  frame : 1;yMax : 633.5	1
23:05:22.323  frame : 1;yMax : 633.5	1
23:05:22.364  -------------------------------------------------------------
23:05:22.364  frame : 2;yMax : 570.5	1
23:05:22.364  When changing from 1 to 2, yMax changes to a weird value temporarily
23:05:22.364  -------------------------------------------------------------
23:05:22.395  frame : 2;yMax : 632.5	1
23:05:22.426  frame : 2;yMax : 632.5	1
23:05:22.458  frame : 2;yMax : 632.5	1
23:05:22.489  frame : 2;yMax : 632.5	1
23:05:22.520  frame : 2;yMax : 632.5	1
23:05:22.551  frame : 2;yMax : 632.5	1
23:05:22.583  frame : 2;yMax : 632.5	1
23:05:22.614  frame : 2;yMax : 632.5	1

Any idea what is happening here?

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