Open Craxic opened 8 years ago
Great :) Was it a bug in Snap?
Haha, well, not really. It just assumes that the centre of the sprite is the centre of the canvas you can draw on, which is wrong when you draw a sprite in the top left corner of the canvas, for example. So I just make it base the centre on the middle of all the non-transparent pixels.
Could it be a suggested improvement to Snap, as it seems quite generic?
@aidanlane Done :) https://github.com/jmoenig/Snap--Build-Your-Own-Blocks/pull/1056.
Fantastic work @Craxic, Jens seemed to really like the patch! (just need to use existing bounding box function?)
A user attempted to flip a sprite using the horizontal and vertical flip buttons in the paint editor.
Because the sprite center was not set, it caused the sprite to flip outside the bounds of the editor and disappear. Once the sprite center was chosen, the sprite could be flipped without issue.
The sprite center should be chosen automatically. Investigate if this is still an issue in the newest version of BYOB.