mirror of
https://github.com/Kelsidavis/WoWee.git
synced 2026-05-03 08:03:50 +00:00
feat: display creature subtitle in target frame
Shows the NPC subtitle (e.g. '<Warchief of the Horde>') below the creature name in the target frame, using the subName field already parsed from SMSG_CREATURE_QUERY_RESPONSE. Adds getCachedCreatureSubName() accessor to GameHandler. Matches the official client's presentation.
This commit is contained in:
parent
8cb0f1d0ef
commit
1165aa6e74
2 changed files with 14 additions and 0 deletions
|
|
@ -548,6 +548,11 @@ public:
|
|||
}
|
||||
std::string getCachedPlayerName(uint64_t guid) const;
|
||||
std::string getCachedCreatureName(uint32_t entry) const;
|
||||
// Returns the creature subname/title (e.g. "<Warchief of the Horde>"), empty if not cached
|
||||
std::string getCachedCreatureSubName(uint32_t entry) const {
|
||||
auto it = creatureInfoCache.find(entry);
|
||||
return (it != creatureInfoCache.end()) ? it->second.subName : "";
|
||||
}
|
||||
// Returns the creature rank (0=Normal,1=Elite,2=RareElite,3=Boss,4=Rare)
|
||||
// or -1 if not cached yet
|
||||
int getCreatureRank(uint32_t entry) const {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue