Modernization Fixes & Updates to Default Values (#3)
This commit is contained in:
parent
445eddff68
commit
dcf64091b1
768 changed files with 10507 additions and 14196 deletions
|
|
@ -1,5 +1,6 @@
|
|||
using System;
|
||||
using System.Collections;
|
||||
using System.Collections.Generic;
|
||||
|
||||
namespace Server.Items
|
||||
{
|
||||
|
|
@ -8,7 +9,7 @@ namespace Server.Items
|
|||
/// </summary>
|
||||
public class DualWield : WeaponAbility
|
||||
{
|
||||
public static Hashtable Registry{ get; } = new Hashtable();
|
||||
public static Dictionary<Mobile, DualWieldTimer> Registry{ get; } = new Dictionary<Mobile, DualWieldTimer>();
|
||||
|
||||
public override int BaseMana => 30;
|
||||
|
||||
|
|
@ -29,24 +30,23 @@ namespace Server.Items
|
|||
if (!Validate(attacker) || !CheckMana(attacker, true))
|
||||
return;
|
||||
|
||||
if (Registry.Contains(attacker))
|
||||
DualWieldTimer timer = Registry[attacker];
|
||||
if (timer != null)
|
||||
{
|
||||
DualWieldTimer existingtimer = (DualWieldTimer)Registry[attacker];
|
||||
existingtimer.Stop();
|
||||
timer.Stop();
|
||||
Registry.Remove(attacker);
|
||||
}
|
||||
|
||||
ClearCurrentAbility(attacker);
|
||||
|
||||
attacker.SendLocalizedMessage(1063362); // You dually wield for increased speed!
|
||||
|
||||
attacker.FixedParticles(0x3779, 1, 15, 0x7F6, 0x3E8, 3, EffectLayer.LeftHand);
|
||||
|
||||
Timer t = new DualWieldTimer(attacker,
|
||||
(int)(20.0 + 3.0 * (attacker.Skills[SkillName.Ninjitsu].Value - 50.0) / 7.0)); //20-50 % increase
|
||||
timer = new DualWieldTimer(attacker,
|
||||
(int)(20.0 + 3.0 * (attacker.Skills.Ninjitsu.Value - 50.0) / 7.0)); //20-50 % increase
|
||||
|
||||
t.Start();
|
||||
Registry.Add(attacker, t);
|
||||
timer.Start();
|
||||
Registry.Add(attacker, timer);
|
||||
}
|
||||
|
||||
public class DualWieldTimer : Timer
|
||||
|
|
@ -69,4 +69,4 @@ namespace Server.Items
|
|||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue