public override void Act(StateController controller)
    {
        Transform targetObject = FindNearWorkObject(controller.transform);

        controller.AnimationWalk();
        controller.agent.MoveTo(targetObject.position);
        controller.targetObject = targetObject.gameObject;
    }
Beispiel #2
0
 public override void Act(StateController controller)
 {
     controller.AnimationWalk();
     controller.agent.MoveTo(controller.targetObject.transform.position);
 }