Matrix - Getting children index and touch state in props?

Hi mates,
Sorry to bother you again, I've made lot of progresses reading the forums and documentation, you guys are awesome!

Today I got stuck trying to get a single index and touch state from the matrix properties.

I've this working using script fields, just by using getIndex() and saving to a variable (no problem in there). But I was wondering if this can be done on the matrix props directly, anything like this?

Thanks once more again :raised_hands:

Hello,

I could get the information using a template literals:

p.onTouch = `console.log(${$}, event.type)`

Basically I'm setting the child onValue script.
Not sure if this is a good practice, but it seems to work fine.

1 Like

Thanks again CielsonLopes!

Awesome, that works great, :raised_hands: