Discord
Login
Community
DARK THEME

Clicking a Specific Obeject

I'm trying to remake an old game I had in Scratch but I can't find any way to check if the player clicks a sprite with their mouse. I would use touch.x and touch.y, but I'm not sure if variables can be in a range of numbers.

touch is for touchscreen. There's a mouse variable for mouse coords and buttons. Regardless, there's no build in function for what you described. You need to compare mouse's coords with the coords of your sprite.

https://microstudio.dev/i/SynKrown/screencoordsjs/

https://microstudio.dev/i/Lunaryss/screenextension/

Thank you both for your help!!!

Post a reply

Progress

Status

Preview
Cancel
Post
Validate your e-mail address to participate in the community