Checking the Sides of a Diagonal Line in JavaScript
Consider the moving body (circle) from the previous demonstration (lesson).
We could put a straight diagonal line in front of the ball (circle)
and perform a certain action (like changing the colour of
the ball) just after the ball has crossed the diagonal line
moving from left to right.