Detect which object was clicked from a group

I’m thinking this should be easy, but can’t seem to find any clear answer :expressionless:

I have a group of objects (buttons with digits), so I can use the condition
“The cursor/touch is on digit_buttons”

Is there an easy way to know which button of the group was clicked?

Thanks :slight_smile:

use the same object but with different instance variable, its way simpler and space consuming : D

Ah, right, smart…

And then use animation frames for the different button images I’m guessing?

Thanks for the tip :slight_smile:

update: this ended up working. A single object with one animation with 6 frames, and an object variable “id” (set to 1 through 6).
The animation is set to paused, and the frame to 0 through 5.

On click I can then use “digit_button.Variable(id)”