diff --git a/mod-reforging/src/item_reforge.cpp b/mod-reforging/src/item_reforge.cpp index b8fd8cf..0a581eb 100644 --- a/mod-reforging/src/item_reforge.cpp +++ b/mod-reforging/src/item_reforge.cpp @@ -9,6 +9,7 @@ #include "Tokenize.h" #include "StringConvert.h" #include "SpellMgr.h" +#include "WorldSessionMgr.h" #include "item_reforge.h" ItemReforge::ItemReforge() @@ -805,8 +806,8 @@ void ItemReforge::HandleReload(Player* player, bool apply) const void ItemReforge::HandleReload(bool apply) const { - const SessionMap& sessions = sWorld->GetAllSessions(); - SessionMap::const_iterator itr; + const WorldSessionMgr::SessionMap& sessions = sWorldSessionMgr->GetAllSessions(); + WorldSessionMgr::SessionMap::const_iterator itr; for (itr = sessions.begin(); itr != sessions.end(); ++itr) if (itr->second && itr->second->GetPlayer() && itr->second->GetPlayer()->IsInWorld()) HandleReload(itr->second->GetPlayer(), apply); diff --git a/mod-reforging/src/mod_reforging_playerscript.cpp b/mod-reforging/src/mod_reforging_playerscript.cpp index cdd04b8..09ea3a1 100644 --- a/mod-reforging/src/mod_reforging_playerscript.cpp +++ b/mod-reforging/src/mod_reforging_playerscript.cpp @@ -37,23 +37,23 @@ public: PLAYERHOOK_ON_APPLY_ITEM_MODS_BEFORE }) {} - void OnAfterMoveItemFromInventory(Player* player, Item* it, uint8 /*bag*/, uint8 /*slot*/, bool /*update*/) override + void OnPlayerAfterMoveItemFromInventory(Player* player, Item* it, uint8 /*bag*/, uint8 /*slot*/, bool /*update*/) override { sItemReforge->RemoveReforge(player, it, true); } - void OnDeleteFromDB(CharacterDatabaseTransaction trans, uint32 guid) override + void OnPlayerDeleteFromDB(CharacterDatabaseTransaction trans, uint32 guid) override { trans->Append("DELETE FROM character_reforging WHERE guid = {}", guid); sItemReforge->HandleCharacterRemove(guid); } - void OnLogin(Player* player) override + void OnPlayerLogin(Player* player) override { new SendReforgePackets(player); } - void OnApplyItemModsBefore(Player* player, uint8 slot, bool apply, uint8 itemProtoStatNumber, uint32 statType, int32& val) override + void OnPlayerApplyItemModsBefore(Player* player, uint8 slot, bool apply, uint8 itemProtoStatNumber, uint32 statType, int32& val) override { Item* item = player->GetItemByPos(INVENTORY_SLOT_BAG_0, slot); if (!item)