Skip to content

Commit

Permalink
fix(match2): status icon on upcoming games (#5218)
Browse files Browse the repository at this point in the history
  • Loading branch information
Rathoz authored Dec 17, 2024
1 parent 5b55c97 commit c9199f4
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions components/match2/commons/match_summary_base_ffa.lua
Original file line number Diff line number Diff line change
Expand Up @@ -56,11 +56,11 @@ local MATCH_OVERVIEW_COLUMNS = {
return 'bg-' .. (opponent.advanceBg or '')
end,
value = function (opponent, idx)
if not STATUS_ICONS[opponent.advanceBg] then
if not STATUS_ICONS[opponent.placementStatus] then
return
end
return IconWidget{
iconName = STATUS_ICONS[opponent.advanceBg],
iconName = STATUS_ICONS[opponent.placementStatus],
}
end,
},
Expand Down Expand Up @@ -569,6 +569,11 @@ function MatchSummaryFfa.updateMatchOpponents(match)

-- Sort match level based on final placement & score
Array.sortInPlaceBy(match.opponents, FnUtil.identity, MatchSummaryFfa.placementSortFunction)

-- Set the status of the current placement
Array.forEach(match.opponents, function(opponent, idx)
opponent.placementStatus = ((match.extradata.placementinfo or {})[idx] or {}).status
end)
end

---@param game table
Expand Down

0 comments on commit c9199f4

Please sign in to comment.