This is what I was not able to do following your previous answer. I did try to put hasBeenClicked inside the class, but i didn’t know where. If it is in the constructor, how can I formulate it? I tried this.mousePressed = hasBeenClicked, but didn’t work because hasbeenClicked was not defined. Where do I declare it?
And does the mousePressed function has to be inside the class to? And how the hasBeenClicked and the mousePressed function relate to each other?
I know it must seem like very basics questions - but i’m confused with the class concept (and other concepts too : I’m an enthusiast beginner - i started from a homework assignement for a static game, but decided to take it further with p5.js - which I do just for fun with my teenager / not part of the homework).