Skip to content

Commit

Permalink
System - Real Talent Info Fix
Browse files Browse the repository at this point in the history
  • Loading branch information
CuteOne committed Nov 21, 2023
1 parent a690193 commit 348f63c
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions System/Loader/cBuilder.lua
Original file line number Diff line number Diff line change
Expand Up @@ -174,14 +174,16 @@ function br.loader:new(spec,specName)
local nodes = br._G.C_Traits.GetTreeNodes(treeId)
for _, nodeId in pairs(nodes) do
local node = br._G.C_Traits.GetNodeInfo(configId, nodeId)
local activeid = (node.activeRank > 0 or node.ranksPurchased > 0) and node.activeEntry and node.activeEntry.entryID or node.entryIDs[1]
for _, entryID in pairs(node.entryIDs) do
local entryInfo = br._G.C_Traits.GetEntryInfo(configId,entryID)
local definitionInfo = br._G.C_Traits.GetDefinitionInfo(entryInfo.definitionID)
if definitionInfo.spellID ~= nil then
local rank = node.activeRank
local rank = node.activeRank or 0
local isActive = activeid == entryID and rank > 0
talents[definitionInfo.spellID] = talents[definitionInfo.spellID] or {}
talents[definitionInfo.spellID].active = rank > 0
talents[definitionInfo.spellID].rank = rank
talents[definitionInfo.spellID].active = isActive
talents[definitionInfo.spellID].rank = isActive and rank or 0
end
end
end
Expand Down

0 comments on commit 348f63c

Please sign in to comment.