Exemple #1
0
 void Start()
 {
     state = RamAIState.HIDING;
     agent = GetComponent <NavMeshAgent> ();
     Sheep = FindClosestSheep().transform;
     if (moveTo == null)
     {
         moveTo = getRandomMoveTo();
     }
 }
Exemple #2
0
    public void MakeDecision()
    {
        prevState = state;

        switch (state)
        {
        case RamAIState.IDLE:
            state = Idle();
            break;

        case RamAIState.HIDING:
            state = Hide();
            break;

        case RamAIState.CHASING:
            state = Chase();
            break;

        case RamAIState.HORNY:
            state = Horny();
            break;
        }
    }