Multi touch not working

so this is the code:

and this is the scene:

with one touch it works fine but with two it does not work
did i use it wrong or is this a bug?

1 Like

What do you mean it doesn’t work? What are you expecting, and what does it actually do?

It needs to rotate the tanks when one of the 2 toucjes is in that range

I think it’s a bug with the multitouch touch number. The first touch is #2, the second is #3. Change your touch #1 to #3, and it should work.

I’ve raised it as a bug.

thanks! i thought i did something wrong but that isnt the case

I stood corrected. It is not a bug. Although GDevelop appears to assign touch numbers in the order they are made, it’s not the best practice way to access the touch details and can lead to unexpected behaviours.

Ideally the id each touch should be stored as it is made, and removed as the touch is ended (i.e. a finger taken off the screen).