Detect line line collision in an Untangled game
- by Vish
Pardon me if this is a repeat question,but I've been searching google for vain since the past few days, I'm a flash actionscript game developer who is a bit backward with mathematics, though I find physics both interesting and cool.
Similiar game : Untangled flash game
I have made an untangled game almost to full completion of logic. But, when two lines intersect , I need those intersected or 'tangled' lines to show a different color; red.
It would be really kind of you people if you could suggest an algorithm with / without math for detecting line segment collisions.
I'm basically a person who likes to think 'visually' than 'arithmetically' :)
P.S I'm trying to make a function as
private function isIntersecting(A:Point, B:Point, C:Point, D:Point):Boolean
Thanks in advance.
Vishnu Ajit