mercredi 6 mai 2015

I want to move my character

I want to move my character in a game by pressing on the screen and it should run to the left when you press at the left side of the screen (it is in landscape mode) and to the right if you press at the left side of the screen.

I've already tried some different things but they didn't work because I made something wrong. I have tried using the touchesBegan and touchesEnded functions because I read that it should work making it with these two functions but I had no success.

I'd be grateful if you could help me.

PS: I should say that I don't move the character, I have a ground node, some trees and the character. I moved the trees so that it looked like the character is moving and I'd like to make it this way.

Aucun commentaire:

Enregistrer un commentaire