Third Person Controller moves left or right

I am using the Standard Assets Third Person Controller on Unity 3.4.

It seems that it can only walk forward and backward.

How can I move it to the left or right?

Thanks in advance for your help.

1 Answer

1

Third Person MMO Controller has Sidestep example.

After following [Third Person Controller rotation limitation][2] discussion, I then modified the following ThirdPersonController.js code:

function Update() {

var movement;

if(!movingBack)
{
	movement = transform.forward * moveSpeed + Vector3 (0, verticalSpeed, 0) + inAirVelocity;

    // Add Sidestep. See README on http://u3d.as/content/unity-technologies/third-person-mmo-controller/1Wt
    movement.x += Input.GetAxis ("Sidestep");

	movement *= Time.deltaTime;
}
    ...	

[2]: http://Third Person Controller rotation limitation