A little help with collision detection
Posted: Wed Mar 16, 2011 5:17 am
Hi! I'm Solumin, a general programmer who's just started with game development, Lua, and Love. I've been lurking on the forums for a while, but my issues have become a bit too...involved, shall we say...to be defeated by mere voyeurism. Currently I'm working on a project with my college's game development club. The game in question is a fairly standard platformer with some interesting mechanics based on art and color. I discovered Love while searching for game development information in relation to Lua, which I had heard was quite popular in the games industry. After playing around with it I fell in, heh, love, and have been using it for a couple months now.
However, as the subject of this post suggests, I've been having trouble with collision detection. I'm using HardonCollider for my collision detection needs but I don't really understand what I'm doing. The first tutorial on the HC site covers the basics really well, but I need help with the advanced topics, such as the uses for the different callbacks, the exact nature of the minimum translation vector (it isn't working intuitively for me), groups, spatial hash -- basically, all the stuff that will be covered in the later tutorials. If I understood these topics I would offer to write the tutorials, but I'm having a lot of trouble.
I managed to kludge and futz my way through it, using, for example, shape:collidesWith(...) to check for collision detection and then dealing with it roughly. However, this restricted the system to rectangles only -- no angles, triangles, circles, etc. That leads to really boring levels and unnecessary limitations on other facets of development. I would love to get HC working as it's supposed to.
Anyway, I can post code if you lovely fellows would care to take a gander. Any tips, tricks, and advice in regards to HardonCollider, Love, platformers, and game development in general would be much appreciated.
Thanks!
However, as the subject of this post suggests, I've been having trouble with collision detection. I'm using HardonCollider for my collision detection needs but I don't really understand what I'm doing. The first tutorial on the HC site covers the basics really well, but I need help with the advanced topics, such as the uses for the different callbacks, the exact nature of the minimum translation vector (it isn't working intuitively for me), groups, spatial hash -- basically, all the stuff that will be covered in the later tutorials. If I understood these topics I would offer to write the tutorials, but I'm having a lot of trouble.
I managed to kludge and futz my way through it, using, for example, shape:collidesWith(...) to check for collision detection and then dealing with it roughly. However, this restricted the system to rectangles only -- no angles, triangles, circles, etc. That leads to really boring levels and unnecessary limitations on other facets of development. I would love to get HC working as it's supposed to.
Anyway, I can post code if you lovely fellows would care to take a gander. Any tips, tricks, and advice in regards to HardonCollider, Love, platformers, and game development in general would be much appreciated.
Thanks!