You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
if we just create a Sprite and intialize his body with nonzero offsets, the following calls with offset set to zero will be ignored (just the offsets, not the sizes).
mySprite = game.add.sprite(_x, _y, 'abbaye_texture');
game.physics.enable(mySprite, Phaser.Physics.ARCADE);
mySprite.body.setSize(8, 20, 10, 10); // set the body with an offset
...
mySprite.body.setSize(8, 20, 0, 0); // reset the body to the sprite position is ignored
The problem is at the Phaser.Physics.Arcade.Body#setSize method, with the lines:
There's a little problem with this method.
if we just create a Sprite and intialize his body with nonzero offsets, the following calls with offset set to zero will be ignored (just the offsets, not the sizes).
The problem is at the Phaser.Physics.Arcade.Body#setSize method, with the lines:
I think it should be something like this:
The text was updated successfully, but these errors were encountered: