mirror of
https://github.com/EQEmu/Server.git
synced 2026-05-31 13:16:39 +00:00
[Hotfix] Delete later in RemoveItem second case
This commit is contained in:
+4
-2
@@ -695,9 +695,11 @@ void NPC::RemoveItem(uint32 item_id, uint16 quantity, uint16 slot)
|
|||||||
else if (item->item_id == item_id && item->equip_slot == slot && quantity >= 1) {
|
else if (item->item_id == item_id && item->equip_slot == slot && quantity >= 1) {
|
||||||
if (item->charges <= quantity) {
|
if (item->charges <= quantity) {
|
||||||
m_loot_items.erase(cur);
|
m_loot_items.erase(cur);
|
||||||
safe_delete(item);
|
|
||||||
UpdateEquipmentLight();
|
UpdateEquipmentLight();
|
||||||
if (UpdateActiveLight()) { SendAppearancePacket(AppearanceType::Light, GetActiveLightType()); }
|
if (UpdateActiveLight()) {
|
||||||
|
SendAppearancePacket(AppearanceType::Light, GetActiveLightType());
|
||||||
|
}
|
||||||
|
safe_delete(item);
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
item->charges -= quantity;
|
item->charges -= quantity;
|
||||||
|
|||||||
Reference in New Issue
Block a user