aboutsummaryrefslogtreecommitdiff
path: root/src/server/game/Texts/CreatureTextMgr.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/server/game/Texts/CreatureTextMgr.cpp')
-rw-r--r--src/server/game/Texts/CreatureTextMgr.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/server/game/Texts/CreatureTextMgr.cpp b/src/server/game/Texts/CreatureTextMgr.cpp
index 8a5c052a093..829df1fdf77 100644
--- a/src/server/game/Texts/CreatureTextMgr.cpp
+++ b/src/server/game/Texts/CreatureTextMgr.cpp
@@ -248,7 +248,8 @@ uint32 CreatureTextMgr::SendChat(Creature* source, uint8 textGroup, WorldObject
if (sound)
finalSound = sound;
else if (BroadcastTextEntry const* bct = sBroadcastTextStore.LookupEntry(iter->BroadcastTextId))
- finalSound = bct->SoundID[source->getGender() == GENDER_FEMALE ? 1 : 0];
+ if (uint32 broadcastTextSoundId = bct->SoundID[source->getGender() == GENDER_FEMALE ? 1 : 0])
+ finalSound = broadcastTextSoundId;
if (range == TEXT_RANGE_NORMAL)
range = iter->TextRange;