Esempio n. 1
0
    private void DoCombatGoal(LANKY_GOALS goal)
    {
        switch (goal)
        {
        case LANKY_GOALS.ATTACK_FROM_RANGE: mAttackFromRangeLogic.Run(); break;

        default: break;
        }
    }
Esempio n. 2
0
    public void RunCombatState()
    {
        rBody.constraints = RigidbodyConstraints.None;

        mConResults.CheckAndStoreConditions();

        // Here we find out what our goal is, to attack from a distance, or to attack with a charge.
        mCurGoal = FindCombatGoal();

        // Here we perform that goal, attacking from a distance or attacking with a charge
        DoCombatGoal(mCurGoal);

        // goal is updated with side effects
        mMoveToGoal.MoveToGoal();

        CheckAndHandleDeath();
    }