void Start() { state = BullAIState.HIDING; agent = GetComponent <NavMeshAgent> (); cow = FindClosestCow().transform; if (moveTo == null) { moveTo = getRandomMoveTo(); } }
public void MakeDecision() { prevState = state; switch (state) { case BullAIState.IDLE: state = Idle(); break; case BullAIState.HIDING: state = Hide(); break; case BullAIState.CHASING: state = Chase(); break; case BullAIState.HORNY: state = Horny(); break; } }