- Home /
Question by
whaleinthesea · Dec 06, 2015 at 01:23 PM ·
c#collider2difpointcheckpoint
How to check if point is inside collider?
I want to know if a point is inside a collider. OnMouseOver is no option for me because the collider is not always in the front and I want to call it like this:
if(pointIsInCollider(collider, point))
{
//do stuff...
}
So if the green rectangle is my collider, pointIsInCollider returns true for my red point and false for my blue point.
isincollider-01.jpg
(114.6 kB)
Comment
Your answer
Follow this Question
Related Questions
Multiple Cars not working 1 Answer
Distribute terrain in zones 3 Answers
My if statement won't work 1 Answer
C# if-statement optimization 1 Answer
Illuminating a 3D object's edges OnMouseOver (script in c#)? 1 Answer