Below is my code that currently rotates the character:
if (Input.GetKey(KeyCode.RightArrow))
{
transform.Rotate (Vector3.back);
}
if (Input.GetKey(KeyCode.LeftArrow))
{
transform.Rotate (Vector3.forward);
}
Basically, I got the player moving up, down, left and right to start with.
Then I got the player to be able to rotate.
I then deleted the original movement part of my code, as I just want the player to be able to move up or down on the vertical axis, depending on whether it is facing the up or down direction.
Can anyone help me with this?
Cheers in advance dudes!