collision detection help?
Ok, what I''m trying to do is get some kind of collision detection between a box and a RGB color. I just need something that will check to see if the box is colliding with a certain color in 16 bit. Also, it is DirectX that I''m using and yes it is 2D. So if anyone could please help me I would really appreciate it. Thanks.
Krusty95
First you would have to get the color of the pixel. You could use LPDIRECTDRAWSURFACE->Lock funktion. See directx manuals for help ''how to access video memory directly''
Then check whether the pixel''s coordinates are inside the box.
Hope this helps.
Then check whether the pixel''s coordinates are inside the box.
Hope this helps.
God saw all that he had made. Shit happens sometimes. --the sixth day.
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement
Recommended Tutorials
Advertisement