fix: Fixes various memory leaks and spells (#1786)
### Summary - Fixes various memory leaks related to spells - Fixes Spell Plague - Added ability to determine if `sdi` should take effect for Spell Damage. - Fixes animal form timer ticking non-stop while logged out.
This commit is contained in:
parent
6747168db0
commit
a552cf4138
51 changed files with 4164 additions and 4188 deletions
|
|
@ -2395,13 +2395,17 @@ namespace Server.Mobiles
|
|||
AnimateDeadSpell.Unregister(m_SummonMaster, this);
|
||||
}
|
||||
|
||||
if (Summoned && SummonMaster != null)
|
||||
{
|
||||
SummonFamiliarSpell.Unregister(SummonMaster, this);
|
||||
}
|
||||
|
||||
if (MLQuestSystem.Enabled)
|
||||
{
|
||||
MLQuestSystem.HandleDeletion(this);
|
||||
}
|
||||
|
||||
UnsummonTimer.StopTimer(this);
|
||||
|
||||
StaminaSystem.RemoveEntry(this as IHasSteps);
|
||||
|
||||
base.OnAfterDelete();
|
||||
|
|
|
|||
|
|
@ -1216,7 +1216,7 @@ namespace Server.Mobiles
|
|||
}
|
||||
}
|
||||
|
||||
public static void OnLogin(Mobile from)
|
||||
public static void OnLogin(PlayerMobile from)
|
||||
{
|
||||
if (AccountHandler.LockdownLevel > AccessLevel.Player)
|
||||
{
|
||||
|
|
@ -1253,11 +1253,9 @@ namespace Server.Mobiles
|
|||
return;
|
||||
}
|
||||
|
||||
if (from is PlayerMobile mobile)
|
||||
{
|
||||
VirtueSystem.CheckAtrophies(mobile);
|
||||
mobile.ClaimAutoStabledPets();
|
||||
}
|
||||
VirtueSystem.CheckAtrophies(from);
|
||||
from.ClaimAutoStabledPets();
|
||||
AnimalForm.GetContext(from)?.Timer.Start();
|
||||
}
|
||||
|
||||
private class ServerLockdownNoticeGump : StaticNoticeGump<ServerLockdownNoticeGump>
|
||||
|
|
@ -2561,6 +2559,7 @@ namespace Server.Mobiles
|
|||
PolymorphSpell.StopTimer(this);
|
||||
IncognitoSpell.StopTimer(this);
|
||||
DisguisePersistence.RemoveTimer(this);
|
||||
AnimalForm.RemoveContext(this, true);
|
||||
|
||||
EndAction<PolymorphSpell>();
|
||||
EndAction<IncognitoSpell>();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue