[Solved] Check if I clicked on an object or not


hi everybody,
i want check if click an object ==> score +1
else if click background ==> score - 1
but when i used “The cursor/touch is on an object” condition always if clicked an object ==> -1 and +1, but i want just add 1 !!!


Also add Trigger Once condition to the event so you trigger the action only once when the cursor/touch is on object.

If you have multiple instances of the score object in the scene, it is a bit more complicated, what you want to do then is set an object variable if an instance is clicked then using For each loop, check the value of this variable for each instance to make sure none of the instances is clicked so the background has clicked.


thank you very much
I added “Trigger Once condition”, and a scene variable “backVariable”,