Show which alts have taken a profession knowledge node in tooltip#1108
Conversation
Co-authored-by: derfloh205 <9341090+derfloh205@users.noreply.github.com> Agent-Logs-Url: https://github.com/derfloh205/CraftSim/sessions/f0910d46-2868-475c-8693-e87a3aa9b139
derfloh205
left a comment
There was a problem hiding this comment.
Very good
additionally to the tooltip additions in the specialization info module, include additional tooltip lines when the player hovers over the specialization nodes/prof perks in the specialization tab in the default UI
you might want to use tooltip related api to capture a prof perk / spec node related tooltip and then inject the information there
Co-authored-by: derfloh205 <9341090+derfloh205@users.noreply.github.com> Agent-Logs-Url: https://github.com/derfloh205/CraftSim/sessions/d35641d5-715f-41c4-bc1f-a82281136c75
Done in d38b29a. Added |
…rove data handling
Managing profession knowledge across multiple characters requires cross-referencing external notes to track which alt has taken which specialization node. This adds an "Also taken by" line directly in the node tooltip, surfacing that information in-game — both in CraftSim's own specialization info panel and in the default Blizzard profession specialization UI.
Changes
Util/Const.lua— NewNODE_DATA_ALSO_TAKEN_BYtext keyLocals/enUS.lua— Localization string:"Also taken by: "DB/crafterDB.lua— New methodGetCrafterNamesWithNodeActive(nodeID, excludeCrafterUID)that scans all cached specialization data across all stored crafters to find who has a given node activeClasses/NodeData.lua—GetTooltipText()appends the alt list in yellow when other characters have the node active; guarded against nilrecipeDataModules/SpecializationInfo/UI.lua— NewHookSpecNodeTooltips()function that useshooksecurefunc(TraitNodeButtonMixin, "OnEnter", ...)to inject an "Also taken by" line into the Blizzard default profession specialization UI tooltips; only fires whenProfessionsFrame.SpecPageis visible (preventing interference with class talent tree nodes)Init/Init.lua— CallsHookSpecNodeTooltips()on addon loadWhen multiple alts have taken the same node, the tooltip gains:
This line appears in both the CraftSim specialization info panel tooltip (in yellow) and in the native Blizzard profession spec tab tooltip (in gold). The lookup iterates stored serialization data per-crafter, checking
nodeID+activeacross all cached recipe specialization entries, excluding the currently viewed character.Original prompt
💡 You can make Copilot smarter by setting up custom instructions, customizing its development environment and configuring Model Context Protocol (MCP) servers. Learn more Copilot coding agent tips in the docs.