Basic collosion detection

Started by
0 comments, last by Ys 22 years, 5 months ago
I need help on basic collosion detection with quads ive tried loads of things and cant get it too work also how would i when the collosion occurs to remove that quad from the screen is there a delete quad function or something like that please help me thanks for any help
Im not fat just big boned :)
Advertisement
Well, simple detection would be, well, pretty simple.
When you draw the quad, keep track of where on the screen it is.
And I''m sure you''re trying to detect when it gets to a certain place, so you have those coordinates as well.
If the coordinate of the quad +/- the width/height/whatever is greater/less than where you want to no longer display it, then, stop displaying it.
You don''t have to delete the quad, you just stop drawing the quad and it''ll go away (if you''re clearing the GL_COLOR_BUFFER_BIT at least, which I''m sure you''re doing, I hope)

- Mike
"The important thing to remember when programming is: When you're 90% complete, there's still 50% more to go."

This topic is closed to new replies.

Advertisement