Move in the facing direction (4 sides)
Hi guys,
Is this possible (and this will be my final question for a while).
You have an actor (say a square).
On the screen you have a controler with 4 buttons, each button represent a side of the square.
Button 1 - Top
Button 2 - Bottom
Button 3 - Left side
Button 4 - Right side
If you click on Button 1 - The actor moves up
If you click on Button 2 - The actor goes down
If you click on Button 3 - The actor goes left
If you click on Button 4 - The actor goes right
However, if the square turns upside down (for example, it colides with a wall that knocks it over and the top is now the bottom), if you press button 1 the actor still moves up.
Another way of looking at it would be, if each side of the square was a colour, and you have 4 buttons that represent each side, if you push one of the coloured buttons, it would move in the direction the colour is facing?
UGH, I hope I've explained this ok?
Cheers,
Chris
Is this possible (and this will be my final question for a while).
You have an actor (say a square).
On the screen you have a controler with 4 buttons, each button represent a side of the square.
Button 1 - Top
Button 2 - Bottom
Button 3 - Left side
Button 4 - Right side
If you click on Button 1 - The actor moves up
If you click on Button 2 - The actor goes down
If you click on Button 3 - The actor goes left
If you click on Button 4 - The actor goes right
However, if the square turns upside down (for example, it colides with a wall that knocks it over and the top is now the bottom), if you press button 1 the actor still moves up.
Another way of looking at it would be, if each side of the square was a colour, and you have 4 buttons that represent each side, if you push one of the coloured buttons, it would move in the direction the colour is facing?
UGH, I hope I've explained this ok?
Cheers,
Chris
Comments
If you click on Button 1 - The actor moves up , AND change rotation to 0
If you click on Button 2 - The actor goes down , AND change rotation to 180
If you click on Button 3 - The actor goes left , AND change rotation to 90
If you click on Button 4 - The actor goes right , AND change rotation to 270
"and this will be my final question for a while"
Why? if you have question , ASK , don't be shy !
Roy.
Thank you for your advice - I will give that a go and see what happens.
I just feel that I'm asking LOADS of questions, and I don't really want to annoy anyone by flooding the forum with questions. Ultimately, what I'm trying to do is create a game with loads of mini games.
After doing a little bit of a google, I've stumbled upon an already made game (also via GameSalad) that has exactly the same control that I would ideally like to achieve.
The game is called Square Jump.
http://itunes.apple.com/us/app/square-jump-lite/id435870419?mt=8
It's a shame as I thought the idea was original, however, it would be great to still try and work out how its done.
Thanks again guys, I do appreciate your help.
Cheers,
Chris