diff --git a/src/game/Object.cpp b/src/game/Object.cpp index 6d1a2b2fd..f5477faa0 100644 --- a/src/game/Object.cpp +++ b/src/game/Object.cpp @@ -1555,11 +1555,13 @@ void WorldObject::MonsterYell(int32 textId, uint32 language, uint64 TargetGuid) cell.data.Part.reserved = ALL_DISTRICT; cell.SetNoCreate(); + float range = sWorld.getConfig(CONFIG_LISTEN_RANGE_YELL); + MaNGOS::MonsterChatBuilder say_build(*this, CHAT_MSG_MONSTER_YELL, textId,language,TargetGuid); MaNGOS::LocalizedPacketDo say_do(say_build); - MaNGOS::PlayerDistWorker > say_worker(this,sWorld.getConfig(CONFIG_LISTEN_RANGE_YELL),say_do); + MaNGOS::PlayerDistWorker > say_worker(this,range,say_do); TypeContainerVisitor >, WorldTypeMapContainer > message(say_worker); - cell.Visit(p, message, *GetMap(), *this, sWorld.getConfig(CONFIG_LISTEN_RANGE_YELL)); + cell.Visit(p, message, *GetMap(), *this, range); } void WorldObject::MonsterYellToZone(int32 textId, uint32 language, uint64 TargetGuid) @@ -1583,11 +1585,13 @@ void WorldObject::MonsterTextEmote(int32 textId, uint64 TargetGuid, bool IsBossE cell.data.Part.reserved = ALL_DISTRICT; cell.SetNoCreate(); + float range = sWorld.getConfig(IsBossEmote ? CONFIG_LISTEN_RANGE_YELL : CONFIG_LISTEN_RANGE_TEXTEMOTE); + MaNGOS::MonsterChatBuilder say_build(*this, IsBossEmote ? CHAT_MSG_RAID_BOSS_EMOTE : CHAT_MSG_MONSTER_EMOTE, textId,LANG_UNIVERSAL,TargetGuid); MaNGOS::LocalizedPacketDo say_do(say_build); - MaNGOS::PlayerDistWorker > say_worker(this,sWorld.getConfig(CONFIG_LISTEN_RANGE_TEXTEMOTE),say_do); + MaNGOS::PlayerDistWorker > say_worker(this,range,say_do); TypeContainerVisitor >, WorldTypeMapContainer > message(say_worker); - cell.Visit(p, message, *GetMap(), *this, sWorld.getConfig(IsBossEmote ? CONFIG_LISTEN_RANGE_YELL : CONFIG_LISTEN_RANGE_TEXTEMOTE)); + cell.Visit(p, message, *GetMap(), *this, range); } void WorldObject::MonsterWhisper(int32 textId, uint64 receiver, bool IsBossWhisper) diff --git a/src/shared/revision_nr.h b/src/shared/revision_nr.h index 4ddc1cd9d..0ad0b179f 100644 --- a/src/shared/revision_nr.h +++ b/src/shared/revision_nr.h @@ -1,4 +1,4 @@ #ifndef __REVISION_NR_H__ #define __REVISION_NR_H__ - #define REVISION_NR "9255" + #define REVISION_NR "9256" #endif // __REVISION_NR_H__