/// <summary> /// Execute Handler /// Cast the According Spell /// </summary> /// <param name="living">Living Executing Ability</param> public override void Execute(GameLiving living) { base.Execute(living); if (Spell != null && SpellLine != null) living.CastSpell(this); }
public override void Execute(GameLiving living) { if (CheckPreconditions(living, DEAD | SITTING | MEZZED | STUNNED)) { return; } SpellLine spline = SkillBase.GetSpellLine(GlobalSpellsLines.Character_Abilities); Spell abSpell = SkillBase.GetSpellByID(7045); if (spline != null && abSpell != null) { foreach (GameNPC enemy in living.GetNPCsInRadius(750)) { if (enemy.IsAlive && enemy.Brain != null) { if (enemy.Brain is IControlledBrain) { living.CastSpell(abSpell, spline); } } } } DisableSkill(living); }
/// <summary> /// Execute Handler /// Cast the According Spell /// </summary> /// <param name="living">Living Executing Ability</param> public override void Execute(GameLiving living) { base.Execute(living); if (Spell != null && SpellLine != null) { living.CastSpell(this); } }
public override void Activate(GameLiving living, bool sendUpdates) { base.Activate(living, sendUpdates); var spell = Spell; var line = SpellLine; if (line != null && spell != null && spell.Target.ToLower().Equals("self")) { living.CastSpell(this); } }
public override void Execute(GameLiving living) { if (CheckPreconditions(living, DEAD | SITTING | MEZZED | STUNNED)) return; SpellLine spline = SkillBase.GetSpellLine(GlobalSpellsLines.Character_Abilities); Spell abSpell = SkillBase.GetSpellByID(7045); if (spline != null && abSpell != null) { foreach (GameNPC enemy in living.GetNPCsInRadius(750)) { if (enemy.IsAlive && enemy.Brain!=null) if(enemy.Brain is IControlledBrain) living.CastSpell(abSpell, spline); } } DisableSkill(living); }