void OnTriggerExit(Collider other) { if (other.tag == tagToDetect) { objectDetected = false; targetObject = null; foxAIController.ExitChase(); //this.GetComponentInParent<Fox>().OnCollisionExitChild(); } }
public void EatFood(int valueToAdd) { UIManager.instance.CreateFeedbackIcon(foxTransform, FeedbackIconType.happy); foxAI.ExitChase(); fullness += valueToAdd; if (fullness > 100) { fullness = 100; } //movementController.objectTarget = null; //movementController.hasTarget = false; }