benilla-re systems structs docs

RebuildBattlefieldScores

function · ui · primitive

Address
0x4aa200 · 336 bytes, up to 0x4aa34f
Meaning
Sets each row's team, counts the filtered rows, sorts the scores and signals UPDATE_BATTLEFIELD_SCORE
Confidence
verified, proof one
Finding
ui/battlefield#names-and-the-score-order

Finding: Names and the score order in ui: battlegrounds

Opcode 0x2e0, 0x4aab30: u8 ended, u8 winner only when ended is nonzero, u32 count, then per row u64 guid, u32 rank, u32 kills, u32 honorableKills, u32 deaths, u32 honor, u32 statCount and that many words, of which eight are kept. The count is not clamped to 80. Each row asks the name cache; a miss adds one to 0xb6ebd4 and the callback 0x4a9ef0 rebuilds when the count reaches zero. 0x4aa200 returns while names are pending; else it sets each row's team (0 for a race whose faction template has flag 0x4, 1 for flag 0x2, else -1), counts the rows of the filter's team, or all rows for -1, sorts the array and signals UPDATE_BATTLEFIELD_SCORE.

The derivation is in the doc.

Callers 3

Callees 3

Calls and jumps by a bare address, from tables/calls.tsv.