// Use this for initialization
 private void Start()
 {
     globalMovement = GameObject.Find("GlobalStateMachine").GetComponent <GlobalSquadMovement>();
     agent          = GetComponent <UnityEngine.AI.NavMeshAgent>();
     detection      = GetComponentInChildren <Detection>();
     _SM            = GetComponent <StateMachine>();
 }
    // Use this for initialization
    private void Start()
    {
        player = GameObject.Find("Player");
        _GSM   = GameObject.Find("GlobalStateMachine").GetComponent <GlobalSquadMovement>();

        _GS = GameObject.Find("GlobalStateMachine").GetComponent <GlobalStateMachine>();
    }