X-Git-Url: http://de.git.xonotic.org/?p=xonotic%2Fxonstat.git;a=blobdiff_plain;f=xonstat%2Ftemplates%2Fplayer_info.mako;h=8f7985968c2173b21e56001973d8bbbd5de2935c;hp=8bb282fa0d44e77dc6228fea777bf40923075acf;hb=c44ff3f4a0f7d2084dd0296dd96682e3b7fd2629;hpb=e031b6fdf4edb778b801fc254a80fedced0b4603 diff --git a/xonstat/templates/player_info.mako b/xonstat/templates/player_info.mako index 8bb282f..8f79859 100644 --- a/xonstat/templates/player_info.mako +++ b/xonstat/templates/player_info.mako @@ -1,457 +1,292 @@ <%inherit file="base.mako"/> <%namespace name="nav" file="nav.mako" /> -<%namespace file="accuracy.mako" import="accuracy" /> <%block name="navigation"> -${nav.nav('players')} + % if player.email_addr is not None: + ${nav.nav('players', True)} + % else: + ${nav.nav('players', False)} + % endif %block> -<%block name="js"> - % if player is not None: - - - - - - - % endif +<%block name="js"> + ${parent.js()} + + + + + %block> <%block name="title"> -Player Information + Player Information %block> - -% if player is None: -
Seriously though, he probably doesn't exist...just a figment of your imagination. Carry on then!
- -% else:+
% if g.game_type_cd in overall_stats:
- Last Played: ${overall_stats[g.game_type_cd].last_played_fuzzy}
+ Last Played: ${overall_stats[g.game_type_cd].last_played_fuzzy}
+ % else:
+
% endif
- Games Played: ${g.games}
+ Games Played:
+ % if g.game_type_cd == 'overall':
+
+ % else:
+
+ % endif
+ ${g.games}
+
+ Playing Time: ${overall_stats[g.game_type_cd].total_playing_time}
% if g.game_type_cd in fav_maps:
- Favorite Map: ${fav_maps[g.game_type_cd].map_name}
+ Favorite Map: ${fav_maps[g.game_type_cd].map_name}
+ % else:
+
% endif
+ % if g.game_type_cd == 'ctf':
+ % if overall_stats[g.game_type_cd].total_captures is not None:
+ Fastest flag captures...
+ % else:
+
+ % endif
+ % else:
+
+ % endif
+
Win Percentage: ${round(g.win_pct,2)}% (${g.wins} wins, ${g.losses} losses)
-
+
% if g.game_type_cd in overall_stats:
% if overall_stats[g.game_type_cd].k_d_ratio is not None:
- Kill Ratio: ${round(overall_stats[g.game_type_cd].k_d_ratio,2)} (${overall_stats[g.game_type_cd].total_kills} kills, ${overall_stats[g.game_type_cd].total_deaths} deaths)
+ Kill Ratio: ${round(overall_stats[g.game_type_cd].k_d_ratio,2)} (${overall_stats[g.game_type_cd].total_kills} kills, ${overall_stats[g.game_type_cd].total_deaths} deaths)
% endif
+ % else:
+
% endif
% if g.game_type_cd in elos:
% if g.game_type_cd == 'overall':
- Best Elo: ${round(elos[g.game_type_cd].elo,2)} (${elos[g.game_type_cd].game_type_cd}, ${elos[g.game_type_cd].games} games)
+ Best Elo: ${round(elos[g.game_type_cd].elo,2)} (${elos[g.game_type_cd].game_type_cd}, ${elos[g.game_type_cd].games} games)
% else:
- Elo: ${round(elos[g.game_type_cd].elo,2)} (${elos[g.game_type_cd].games} games)
+ Elo: ${round(elos[g.game_type_cd].elo,2)} (${elos[g.game_type_cd].games} games)
% endif
+ % else:
+
% endif
% if g.game_type_cd in ranks:
% if g.game_type_cd == 'overall':
- Best Rank: ${ranks[g.game_type_cd].rank} of ${ranks[g.game_type_cd].max_rank} (${ranks[g.game_type_cd].game_type_cd})
-
+ Best Rank:
+
+
+ ${ranks[g.game_type_cd].rank} of ${ranks[g.game_type_cd].max_rank}
+
+ (${ranks[g.game_type_cd].game_type_cd}, percentile: ${round(ranks[g.game_type_cd].percentile,2)})
+
+
% else:
- Rank: ${ranks[g.game_type_cd].rank} of ${ranks[g.game_type_cd].max_rank}
+ Rank:
+
+
+ ${ranks[g.game_type_cd].rank} of ${ranks[g.game_type_cd].max_rank}
+
+ (percentile: ${round(ranks[g.game_type_cd].percentile,2)})
+
+
% endif
+ % else:
+
% endif
% if g.game_type_cd == 'ctf':
- % if overall_stats[g.game_type_cd].cap_ratio is not None:
+ % if overall_stats[g.game_type_cd].cap_ratio is not None:
Cap Ratio: ${round(overall_stats[g.game_type_cd].cap_ratio,2)} (${overall_stats[g.game_type_cd].total_captures} captures, ${overall_stats[g.game_type_cd].total_pickups} pickups)
+ % else:
+
% endif
+ % else:
+
% endif
-
- | Type | -Server | -Map | -Result | -Played | -
---|---|---|---|---|---|
view | -- | ${server.name} | -${map.name} | -- % if gamestat.team != None: - % if gamestat.team == game.winner: - Win - % else: - Loss - % endif - % else: - % if gamestat.rank == 1: - Win - % else: - Loss (#${gamestat.rank}) - % endif - % endif - | -${game.fuzzy_date()} | -
+ | Type | +Server | +Map | +Result | +Played | +Elo | +
---|---|---|---|---|---|---|
view | ++ | ${rg.server_name} | +${rg.map_name} | ++ % if rg.team != None: + % if rg.team == rg.winner: + Win + % else: + Loss + % endif + % else: + % if rg.rank == 1: + Win + % else: + Loss (#${rg.rank}) + % endif + % endif + | +${rg.fuzzy_date} | ++ + % if rg.elo_delta is not None: + % if round(rg.elo_delta,2) > 0: + +${round(rg.elo_delta,2)} + % elif round(rg.elo_delta,2) < 0: + ${round(rg.elo_delta,2)} + % else: + + % endif + % else: + + % endif + + | +
+ More... +
+ % endif + +