Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
Implement spatial hashing for sprite collision detection #189
What should be added/changed?
Right now, checking to see if a sprite collides with other sprites in a list is an O(n) operation. Using Spatial Hashing, we should be able to make this a lot faster by only checking sprites that are close by.
What would it help with?
This should improve performance for programs with a lot of sprites. Particularly those with tiles.