Touch in mobile devices issue

Hello, It’s me here again.

I have some issues to resolve with the project I am currently working on.

1. In this scene I can select some part of the body, but when I run the game on the tablet or on the andorid phone it does not recognize the touch. That is, it does not keep the pressed part selected.
It working on touch devices the condition of cursor/touch is on an object or i need to configure it in a different way?

The same goes for the slider, it doesn’t recognize it
And I can’t display the mobile keyboard either. In the web version it works fine. This are the events that i used to configure mobile and not mobile keyboard:

I have tested the multitouch download project: Link ,and it works fine on tablet and smartphone, but this is just about moving the cursor.

2. The other thing I try to do is to be able to store the values ​​indicated in the slider scene in some kind of array. I have not found much information about this, I mean nothing specific to a value in a slider or something dynamic, I do not know if I am understood.

I don’t understand how the code you have provided is connected to the screen shot. In the screen shot there are no buttons visible. And in the code there’s nothing about touch on a body part.

Can you show the code that matches the scene screen shot?

Thanks for the answer MrMen. Sorry if I was not clear in the explanation. I did not show the virtual controls before because it was not from a mobile device. But here is how it would look, the only thing here (from the PC) if I can keep the selection of the parts of the body that I click (it turns red if it is selected, and I de-select it by touching outside the blue circle), instead this it doesn’t happen neither on the tablet or on the smarthphone

This is the code for the virtual controls and for the slection event on any part of the body, i just put here the left shoulder because is the same for the others.

To get an understanding of what is happening, when you touch the body part on the tablet/phone version, does it change colour at all if you hold touch down? And when you let go? Or does it not change colour at all?

And what happens if you enable move mouse cursor when touching screen?

That makes 4 questions btw :slight_smile:

1 Like

First, if all body parts work the same way, use an object group to use the same block of events for all body parts and avoid duplicates and copypasting.
Second, this might be a case where you should use a cursor object and replace cursor is on object by cursorObject is in collision with object.

1 Like

When I touch any body part in the tablet/phone it change the color, but doesn’t keep the selecction. The same happens on the slider, it recognize that I touch it, but it doesn’t allow to move the slider.

What do you mean with enable move mouse cursor?

Does it have the same outcome if you keep your finger on the body part? If not, then try setting “Move mouse cursor when touching screen” to “yes” (enabling it).


Yes it’s the same when i keep the finger on a body part, doesn’t keep the part selected if i stop touch it.

And i changed to “Yes” the move mouse cursor action, but still the same :confused: Maybe i should try setting a cursor or something like that.

Try @Gruk’s suggestion first :

If that doesn’t make a difference, we’ll have a go at refactoring your events.

Are those all the events for left shoulder? Is there anything for when select of LeftShoulder = 1.

And is the select instance variables used anywhere else? If not, we may be able to refactor your events.