I need to make it so when you tap on the left side of the player you move left, and the right side you move right. I am making it top down, and for some reason Simulate Control isnt working properly.
Develop games in your browser. Powerful, performant & highly capable.
create a global variable, let's call it MOVING
On tap left set MOVING to 1
On tap right set MOVING to 2
System compare variable
MOVING = 1 - simulate pressing left
MOVING = 2 - simulate pressing right
on touch is only true for 1 tick, you could also use is touching if you prefer.
Here is the capx so you can see what I did. You need a touch device, our you could just change it to mouse. When I click on the right side of the screen, the layout restarts. And I know its simulate control up and down, I was just testing. Change it back to left and right. Try to find out why left and right aren't working.
Removed a lot
The touch object accepts mouse input if you don't change it, so there was no need to change anything. Can test it on windows in Chrome just fine with my mouse.