MoonMay Posted June 10, 2018 Share Posted June 10, 2018 Hi all. I try to get width/height properties in pixels with object PIXI.extras.AnimatedSprite but all time it return 1. How i can do that? In the object this properties is true console.log Quote Link to comment Share on other sites More sharing options...
ivan.popelyshev Posted June 10, 2018 Share Posted June 10, 2018 Its always 1 before its loaded. People often forget that "Texture.fromImage("xxx.png").width" cant possibly return width because the image will be loaded later. MoonMay 1 Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.