on-internet
← Community

Phaser texture atlas wrong dimensions

Stack Overflow ·

I was using spritesheets in my game, but I had come to a problem, that I wanted my character to duck (to dodge bullets). I found out that I can use texture atlas. Based on what I have read, I thought, that this approach will resize the sprite, based on its current animation. So when I would duck, the sprite would change its height, because the frame for ducking is less high that the frame for standing. I load the atlas like: game.load.atlasJSONHash('player', '../assets/images/player/player.png', '../assets/images/player/player.json'); I can see that the dimensions in the json are right, that t

Comments

Sign in or sign up to comment and upvote.

No comments yet.