Fixes dictionary uses (#7)

This commit is contained in:
Kamron Batman 2018-11-02 08:16:42 -07:00 • committed by GitHub
parent d4a52344f2
commit 916d404c51
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
161 changed files with 1211 additions and 1722 deletions

View file

@ -8,7 +8,7 @@ namespace Server.Items
/// </summary>
public class TalonStrike : WeaponAbility
{
private static Dictionary<Mobile, InternalTimer> m_Table = new Dictionary<Mobile, InternalTimer>();
private static HashSet<Mobile> m_Table = new HashSet<Mobile>();
public override int BaseMana => 30;
public override double DamageScalar => 1.2;
@ -27,7 +27,7 @@ namespace Server.Items
public override void OnHit(Mobile attacker, Mobile defender, int damage)
{
if (m_Table.ContainsKey(defender) || !Validate(attacker) || !CheckMana(attacker, true))
if (m_Table.Contains(defender) || !Validate(attacker) || !CheckMana(attacker, true))
return;
ClearCurrentAbility(attacker);
@ -42,7 +42,7 @@ namespace Server.Items
timer.Start();
m_Table.Add(defender, timer);
m_Table.Add(defender);
}
private class InternalTimer : Timer