Resolve emote text from DBC for other players' text emotes

Load third-person emote text templates (othersTarget/othersNoTarget)
from EmotesText.dbc fields 3 and 7 alongside existing sender text.
Build reverse lookup map from dbcId to EmoteInfo for incoming
SMSG_TEXT_EMOTE resolution. Other players now show proper emote
descriptions like "Player dances with Target" instead of generic
"Player performs an emote" text.
This commit is contained in:
Kelsi 2026-02-14 15:11:43 -08:00
parent a90c130d6e
commit 3acb42b363
5 changed files with 118 additions and 38 deletions

View file

@ -105,8 +105,11 @@ void DBCLayout::loadWotlkDefaults() {
layouts_["Emotes"] = {{{ "ID", 0 }, { "AnimID", 2 }}};
// EmotesText.dbc
// Fields 3-18 are 16 EmotesTextData refs: [others+target, target+target, sender+target, ?,
// others+notarget, ?, sender+notarget, ?, female variants...]
layouts_["EmotesText"] = {{{ "Command", 1 }, { "EmoteRef", 2 },
{ "SenderTargetTextID", 5 }, { "SenderNoTargetTextID", 9 }}};
{ "OthersTargetTextID", 3 }, { "SenderTargetTextID", 5 },
{ "OthersNoTargetTextID", 7 }, { "SenderNoTargetTextID", 9 }}};
// EmotesTextData.dbc
layouts_["EmotesTextData"] = {{{ "ID", 0 }, { "Text", 1 }}};