Mobile Controls


#1

I’ve wanted to make a mobile version of a game I’ve been working on. Although, I never actually made a mobile game or app on Playcanvas. I want a D-pad like controls.

Does anyone know how I could code something like that in?


#2

You can add UI buttons to act as controls. There’s a few UI tutorials here: https://developer.playcanvas.com/en/user-manual/user-interface/


#3

Thanks! I will see if I can implement the controls now.


#4

I have tried using the touch controls on a sample project but it doesn’t work. I even tried adding mouse input so when I clicked the image element, the player should move. The player didn’t move. Can you show me how to set up my code correctly, because I think that the problem’s in my code.