Improved the sprite editor, removed several bugs