Skip to main content
gamedev.net
🔒 Locked

2D collision detection

Started by Wayfarer 1 reply 650+ views
Original Post
Wayfarer
Wayfarer
How to do 2D collision detection between a triangle and a rectangle?
Meduzza
Meduzza
for every rectangle side
for every triangle side
check if triangle side crossez rectangle side
Wayfarer
Wayfarer
Nice. I was doing a bunch of point in trig and point on line tests
for every vertex.
I can just check for line intersections doing your method.

Topic Locked

This topic has been locked by a moderator. New replies are not allowed.

Sign in to reply to this topic.