mirror of
https://github.com/mangosfour/server.git
synced 2025-12-15 10:37:02 +00:00
[9245] Remove CellLock class and all cell-level thread locking.
* It was wasting CPU power as cell-level locking is not needed. * Future multithreading will be on map-level. * CellLock was just a 'proxy' between Cell and CellPair and in some cases carried redundant data. * Some minor cleanup in Cell::Visit/Map::Visit.
This commit is contained in:
parent
39b7636094
commit
0ff9250de2
19 changed files with 104 additions and 209 deletions
|
|
@ -582,8 +582,7 @@ void WorldSession::HandleTextEmoteOpcode( WorldPacket & recv_data )
|
|||
MaNGOS::LocalizedPacketDo<MaNGOS::EmoteChatBuilder > emote_do(emote_builder);
|
||||
MaNGOS::PlayerDistWorker<MaNGOS::LocalizedPacketDo<MaNGOS::EmoteChatBuilder > > emote_worker(GetPlayer(), sWorld.getConfig(CONFIG_LISTEN_RANGE_TEXTEMOTE), emote_do);
|
||||
TypeContainerVisitor<MaNGOS::PlayerDistWorker<MaNGOS::LocalizedPacketDo<MaNGOS::EmoteChatBuilder > >, WorldTypeMapContainer> message(emote_worker);
|
||||
CellLock<GridReadGuard> cell_lock(cell, p);
|
||||
cell_lock->Visit(cell_lock, message, *GetPlayer()->GetMap(), *GetPlayer(), sWorld.getConfig(CONFIG_LISTEN_RANGE_TEXTEMOTE));
|
||||
cell.Visit(p, message, *GetPlayer()->GetMap(), *GetPlayer(), sWorld.getConfig(CONFIG_LISTEN_RANGE_TEXTEMOTE));
|
||||
|
||||
GetPlayer()->GetAchievementMgr().UpdateAchievementCriteria(ACHIEVEMENT_CRITERIA_TYPE_DO_EMOTE, text_emote, 0, unit);
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue