feat: support /use macros for action bar icon and indicators

Macros with /use ItemName (e.g. /use Healthstone, /use Engineering
trinket) had no icon, cooldown, or tooltip on the action bar because
only /cast and /castsequence were recognized. Now the spell resolution
also handles /use by looking up the item name in the item info cache
and finding its on-use spell ID. Added getItemInfoCache() accessor.
This commit is contained in:
Kelsi 2026-03-20 09:08:49 -07:00
parent b960a1cdd5
commit 6bd950e817
2 changed files with 25 additions and 6 deletions

View file

@ -2194,6 +2194,7 @@ public:
auto it = itemInfoCache_.find(itemId);
return (it != itemInfoCache_.end()) ? &it->second : nullptr;
}
const std::unordered_map<uint32_t, ItemQueryResponseData>& getItemInfoCache() const { return itemInfoCache_; }
// Request item info from server if not already cached/pending
void ensureItemInfo(uint32_t entry) {
if (entry == 0 || itemInfoCache_.count(entry) || pendingItemQueries_.count(entry)) return;