private void CatchPatrolPath() { if (patrolPath == null) { patrolPath = patrolPathGenerator.CreateEmptyPatrolPath(transform.position); } }
private void Start() { fighter = GetComponent <Fighter>(); health = GetComponent <Health>(); player = GameObject.FindWithTag("Player"); mover = GetComponent <Mover>(); guardPosition = transform.position; if (patrolPath == null) { patrolPath = FindObjectOfType <PatrolPath>(); } }