// Name should be the FightingObjectView.GetSpellCasted().d6 public DangerousSpell(SpellTarget target, SpellCategory category, Evade evadeMethod, string spellName) { this.name = spellName; this.target = target; this.category = category; this.evadeMethod = evadeMethod; }
public void AddSpellToMob(string mobName, SpellCategory category, SpellTarget target, Evade evade, string spellName = null) { DangerousSpell spell = new DangerousSpell(target, category, evade, spellName); var mob = GetMobByName(mobName); if (mob != null) { AddSpellToMob(mob, spell); } }
public DangerousSpell GetSpell(SpellCategory category, SpellTarget target) { foreach (var spell in dangerousSpells) { if (spell.IsNamed()) { continue; } if (spell.GetCategory().Equals(category) && spell.GetTarget().Equals(target)) { return(spell); } } return(null); }
public static IEnumerable <Spell> Category(this IEnumerable <Spell> spells, gz.SpellCategory category) { return(spells.Where <Spell>(spell => spell.Category == category)); }