//Initial Setup void Start() { behaviour = GetComponent <AI_BehaviourCollection>(); _player = GameObject.Find("Player"); prevState = AI_SensorySystem.AlertnessStates.Low; _canCheat = true; }
//Function that is called by Sensory System to send its info here public void RecieveSensoryInfo(AI_SensorySystem.SensoryInfo _info) { if (!BlockingSensoryInfo) { prevState = info._alertnessState; info = _info; if (info.isSeeingPlayer) { lastSeenPlayer = _player.transform.position; _canCheat = true; } HandleIdleTicks(); MakeDecision(); } else { behaviour.Stop(); } }