fix: Blood Oath, Wraith form, & Strangle (#1153)
Fixes blood oath mechanic, and wraith form not properly leeching.
This commit is contained in:
parent
c5d2a58917
commit
1e50ff9966
10 changed files with 52 additions and 78 deletions
|
|
@ -62,7 +62,7 @@ namespace Server.Spells
|
|||
|
||||
public static class SpellHelper
|
||||
{
|
||||
private static readonly TimeSpan AosDamageDelay = TimeSpan.FromSeconds(1.0);
|
||||
private static readonly TimeSpan AosDamageDelay = TimeSpan.FromSeconds(1.25);
|
||||
private static readonly TimeSpan OldDamageDelay = TimeSpan.FromSeconds(0.5);
|
||||
|
||||
private static readonly TimeSpan CombatHeatDelay = TimeSpan.FromSeconds(30.0);
|
||||
|
|
@ -1014,11 +1014,6 @@ namespace Server.Spells
|
|||
|
||||
var damageGiven = AOS.Damage(target, from, dmg, phys, fire, cold, pois, nrgy, chaos);
|
||||
|
||||
if (from != null) // sanity check
|
||||
{
|
||||
DoLeech(damageGiven, from, target);
|
||||
}
|
||||
|
||||
WeightOverloading.DFA = DFAlgorithm.Standard;
|
||||
}
|
||||
else
|
||||
|
|
@ -1049,23 +1044,14 @@ namespace Server.Spells
|
|||
|
||||
if (context.Type == typeof(WraithFormSpell))
|
||||
{
|
||||
var wraithLeech =
|
||||
5 + (int)(15 * from.Skills.SpiritSpeak.Value / 100); // Wraith form gives 5-20% mana leech
|
||||
var manaLeech = AOS.Scale(damageGiven, wraithLeech);
|
||||
|
||||
if (manaLeech != 0)
|
||||
{
|
||||
from.Mana += manaLeech;
|
||||
from.PlaySound(0x44D);
|
||||
}
|
||||
WraithFormSpell.DoWraithLeech(from, target, damageGiven);
|
||||
}
|
||||
else if (context.Type == typeof(VampiricEmbraceSpell))
|
||||
{
|
||||
from.Hits += AOS.Scale(damageGiven, 20);
|
||||
from.Hits += Math.Min(target.Hits, AOS.Scale(damageGiven, 20));
|
||||
from.PlaySound(0x44D);
|
||||
}
|
||||
}
|
||||
|
||||
public static void Heal(int amount, Mobile target, Mobile from, bool message = true)
|
||||
{
|
||||
// TODO: All Healing *spells* go through ArcaneEmpowerment
|
||||
|
|
@ -1159,11 +1145,6 @@ namespace Server.Spells
|
|||
|
||||
var damageGiven = AOS.Damage(m_Target, m_From, m_Damage, m_Phys, m_Fire, m_Cold, m_Pois, m_Nrgy, m_Chaos);
|
||||
|
||||
if (m_From != null) // sanity check
|
||||
{
|
||||
DoLeech(damageGiven, m_From, m_Target);
|
||||
}
|
||||
|
||||
WeightOverloading.DFA = DFAlgorithm.Standard;
|
||||
|
||||
if (bcTarg != null && m_From != null)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue