GetNextSpell() 공개 메소드

public GetNextSpell ( ) : Spell,
리턴 Spell,
예제 #1
0
    private void GetNextSpellOrEndGame(string spellType = null)
    {
        Spell nextSpell;

        if (string.IsNullOrEmpty(spellType))
        {
            nextSpell = spellList.GetNextSpell();
        }
        else
        {
            nextSpell = spellList.GetSpellOfType(spellType);
        }

        curSpell = nextSpell;

        if (nextSpell != null)
        {
            nextSpell.OnStateChange += OnSpellOver;
            nextSpell.StartSpell();
        }
        else
        {
            EndGame();
        }
    }