1 <%def name="scoreboard(game_type_cd, pgstats, show_elo=False)">
2 <table class="table table-bordered table-condensed">
3 ${scoreboard_header(game_type_cd, pgstats[0])}
5 % for pgstat in pgstats:
6 <tr class="${pgstat.team_html_color()}">
8 % if pgstat.player_id > 2:
9 <a href="${request.route_url("player_info", id=pgstat.player_id)}"
10 title="Go to the info page for this player">
11 <span class="nick">${pgstat.nick_html_colors()|n}</span>
14 <span class="nick">${pgstat.nick_html_colors()|n}</span>
17 % if pgstat.avg_latency is not None:
19 ${int(round(pgstat.avg_latency))}
24 ${scoreboard_row(game_type_cd, pgstat)}
25 <td>${pgstat.score}</td>
27 % if pgstat.elo_delta is not None:
28 <td>${round(pgstat.elo_delta,2)}</td>
39 ##### SCOREBOARD HEADER #####
40 <%def name="scoreboard_header(game_type_cd, pgstat)">
41 % if game_type_cd == 'dm' or game_type_cd == 'tdm' or game_type_cd == 'duel':
44 <th class="nick">Nick</th>
45 % if pgstat.avg_latency is not None:
46 <th class="ping">Ping</th>
48 <th class="kills">Kills</th>
49 <th class="deaths">Deaths</th>
50 <th class="suicides">Suicides</th>
51 <th class="score">Score</th>
59 % if game_type_cd == 'ctf':
60 <thead class="ctf ${pgstat.team_html_color()}">
62 <th class="nick">Nick</th>
63 % if pgstat.avg_latency is not None:
64 <th class="ping">Ping</th>
66 <th class="kills">Kills</th>
67 <th class="captures">Captures</th>
68 <th class="pickups">Pickups</th>
69 <th class="fck" title="Flag Carrier Kill">FCK</th>
70 <th class="returns">Returns</th>
71 <th class="score">Score</th>
79 % if game_type_cd == 'ca':
80 <thead class="ca ${pgstat.team_html_color()}">
82 <th class="nick">Nick</th>
83 % if pgstat.avg_latency is not None:
84 <th class="ping">Ping</th>
86 <th class="kills">Kills</th>
87 <th class="score">Score</th>
95 % if game_type_cd == 'freezetag':
96 <thead class="freezetag ${pgstat.team_html_color()}">
98 <th class="nick">Nick</th>
99 % if pgstat.avg_latency is not None:
100 <th class="ping">Ping</th>
102 <th class="kills">Kills</th>
103 <th class="deaths">Deaths</th>
104 <th class="suicides">Suicides</th>
105 <th class="score">Score</th>
114 ##### SCOREBOARD ROWS #####
115 <%def name="scoreboard_row(game_type_cd, pgstat)">
116 % if game_type_cd == 'dm' or game_type_cd == 'tdm' or game_type_cd == 'duel':
117 <td>${pgstat.kills}</td>
118 <td>${pgstat.deaths}</td>
119 <td>${pgstat.suicides}</td>
122 % if game_type_cd == 'ctf':
123 <td>${pgstat.kills}</td>
124 <td>${pgstat.captures}</td>
125 <td>${pgstat.pickups}</td>
126 <td>${pgstat.carrier_frags}</td>
127 <td>${pgstat.returns}</td>
130 % if game_type_cd == 'ca':
131 <td>${pgstat.kills}</td>
134 % if game_type_cd == 'freezetag':
135 <td>${pgstat.kills}</td>
136 <td>${pgstat.deaths}</td>
137 <td>${pgstat.suicides}</td>