I do notice a bit of lag when making changes to the parameters. That’s without any actual collision maths in place. I guess just iterating over the huge amount of line segments is pretty heavy.
Adding the maths for now.
Getting all true all the time. Thinks it’s colliding all the time, probably because the endpoint of one line segment serves as the start point for the next segment. Right?
What if I change this:
if s >= 0 and s <= 1 and t >= 0 and t <= 1:
…to this:
if s > 0 and s < 1 and t > 0 and t < 1:
Nope.
Think I need to do some visual debugging. Draw the intersection point.