private ISpell ExecuteAction(RoundResult rr, ISpell prevSpell = null) { Attack attack; var spell = prevSpell; if (CurrentSpell == null) { spell = GetSpellFromApl(); attack = spell?.Execute(this); // If attack is null we have started a cast if (attack != null) { rr.Attacks.Add(attack); return(spell); } } else { // We have already continued on this cast this turn if (spell != null) { return(null); } // We are already casting attack = CurrentSpell.Continue(this); // If attack is null cast is not complete if (attack != null) { rr.Attacks.Add(attack); return(attack.Spell); } } return(null); }