1 <%def name="frag_matrix(pgstats, matrix_by_pgstat_id)">
3 ## Displays a frag matrix table, in scoreboardpos order from top to bottom and left to right
5 <table class="table-hover table-condensed">
8 % for pgstat in pgstats:
9 <th>${pgstat.nick_html_colors()|n}</th>
13 % for fragger in pgstats:
15 <td>${fragger.nick_html_colors()|n}</td>
16 % for victim in pgstats:
18 pgfm = matrix_by_pgstat_id.get(fragger.player_game_stat_id)
20 victim_pgfm = matrix_by_pgstat_id.get(victim.player_game_stat_id)
22 victim_index = str(victim_pgfm.player_index)
26 <td>${pgfm.matrix.get(victim_index, 0)}</td>