Cleans up Spell Targeting (#36)

This commit is contained in:
Kamron Batman 2019-03-15 15:23:03 -07:00 • committed by GitHub
parent de50bc9e43
commit 472b84f5ff
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
99 changed files with 653 additions and 2192 deletions

View file

@ -469,7 +469,7 @@ namespace Server.Factions
if (m_Guard.Map == toHarm.Map && (targ.Range < 0 || m_Guard.InRange(toHarm, targ.Range)) &&
m_Guard.CanSee(toHarm) && m_Guard.InLOS(toHarm))
targ.Invoke(m_Guard, toHarm);
else if (targ is DispelSpell.InternalTarget)
else if ((targ as ISpellTarget)?.Spell is DispelSpell)
targ.Cancel(m_Guard, TargetCancelType.Canceled);
}
else if ((targ.Flags & TargetFlags.Beneficial) != 0)