I’m trying to do mobile game but I have a problem. I can tell the game not to move the cursor when touching the screen. Except if the player touch the screen before the first scene of the game is displayed, so while the game is loading. So if the player touch somewhere during loading, then it’s as if there’s a non-stop pressure on that part of the screen. I’ve seen that the game can’t move the cursor, so is there a solution to my problem?
I have set move cursor when touching screen to “no”, but if the player touch the screen before the launch of the first scene, it will move the cursor during the loading
What you’re asking it to do is not move the cursor before GDevelop has finished loading. GDevelop has no control over the cursor until it’s loaded. I suspect it’d require a change to the web page that gets loaded. If so, this may be something that’s better answered by the likes of @arthuro555 or @Silver-Streak.
When you touch a white square, it change to red, and when you realese it, it change back to white. So, if you launch the game to a mobile device, if you touch the screen during the loading, it will change the square that is located at the place of the touch to the red, without being able to go back to white. So it means that Gdevelop save the position of the cursor when he is loading, before the first scene have ended loading.
When you touch the screen, the cursor moves to where the touch occurred. This is done by the OS, not GDevelop. When you release the touch, the cursor does not move. It stays at the last touch position. It’s not that GDevelop remembers or saves the position.
Now, you are only testing if the cursor is over the object. Which will trigger as true every single frame while the cursor hasn’t moved. You should be testing "Mouse button pressed or touch held’.
Please don’t resurrect an old post. Start a new one, or better still search GDevelop for previous posts that have solutions to your problem, like this very recent one.