public void walkRight() { Vector3 target = Vector3.right * Random.Range(3, 5) + this.transform.position; currentAction = WalkAction.GetWalkAction(target, walkSpeed, ani); this.runAction(this.gameObject, currentAction, this); }
public void walk() { Vector3 target = new Vector3(Random.Range(-1f, 1f), 0, Random.Range(-1f, 1f)) + transform.position; baseAction = WalkAction.GetWalkAction(target, walkSpeed, animator); this.runAction(this.gameObject, baseAction, this); }
public void walkLeft() { Vector3 target = new Vector3(Random.Range(-1, 1), 0, Random.Range(-1, 1)) + transform.position; currentAction = WalkAction.GetWalkAction(target, walkSpeed, ani); this.runAction(this.gameObject, currentAction, this); }
public void walkForward() { Vector3 target = Vector3.forward * Random.Range(4, 7) + this.transform.position; currentAction = WalkAction.GetWalkAction(target, walkSpeed, ani); this.runAction(this.gameObject, currentAction, this); }
public void walkBack() { Vector3 target = Vector3.back * Random.Range(3, 5) + this.transform.position; action = WalkAction.GetWalkAction(walkSpeed, target, animator); this.RunAction(this.gameObject, action, this); }