Menu

#29 Bugfix for Sprite pixel level collision detection

open
nobody
None
5
2008-07-03
2008-07-03
Will Jordan
No

There is a bug in Sprite's pixel level collision detection, which causes the getRGB method to sometimes throw an IllegalArgumentException or return the wrong values. The problem only appears on Sprites with multiple frames when the number of columns does not match the number of rows (for example a 1x3 or 3x2 image).

The fix is small, just requiring switching the 'rows' variable with 'cols' in two places.

Discussion

  • Will Jordan

    Will Jordan - 2008-07-03

    Bugfix patch

     

Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.