Trouble using Ray.Intersect method on bounding boxes in a 2D XNA game
- by getsauce
I am trying to use a ray and bounding box to determine if a box is between the player and the mouse pointer in 2D space. When I try testing the code, the collision will return true when pointed at the box but it also returns true under other circumstances where it shouldn't.
For instance. If I have a player on the left and a box directly to the…