Misc fixes

This commit is contained in:
hondacrx
2020-05-18 22:46:18 -04:00
parent 65c6731974
commit 970d18031c
4 changed files with 10 additions and 4 deletions
+4 -3
View File
@@ -1696,12 +1696,13 @@ namespace Game.Entities
}
if (spell.Value.State == PlayerSpellState.Removed)
m_spells.Remove(spell.Key);
else
{
spell.Value.State = PlayerSpellState.Unchanged;
m_spells.Remove(spell.Key);
continue;
}
if (spell.Value.State != PlayerSpellState.Temporary)
spell.Value.State = PlayerSpellState.Unchanged;
}
}
void _SaveAuras(SQLTransaction trans)
+2 -1
View File
@@ -3912,11 +3912,12 @@ namespace Game.Entities
pItem.RemoveFromWorld();
if (del)
{
pItem.SetState(ItemUpdateState.Removed, this);
ItemTemplate itemTemplate = pItem.GetTemplate();
if (itemTemplate != null)
if (itemTemplate.GetFlags().HasAnyFlag(ItemFlags.HasLoot))
Global.LootItemStorage.RemoveStoredLootForContainer(pItem.GetGUID().GetCounter());
pItem.SetState(ItemUpdateState.Removed, this);
}
}