https://i.imgur.com/1Ud5Fgk.png
I want to make a game in which you draw a line, then click on the red button below for the square near the line to follow the drawn line.
So I have two Mouse event, one is any click to draw the line, and one is click on the red button below for the red square to start moving.
However, when I click on the red button, it recognizes the any click event and spawn another line.
What should I do so the first event isn't recognized when I click on the red button?