}
var previousPoint = null;
+ var previousLabel = null;
$('#acc-graph').bind("plothover", function (event, pos, item) {
if (item) {
- if (previousPoint != item.dataIndex) {
+ if ((previousLabel != item.series.label) || (previousPoint != item.dataIndex)) {
+ previousLabel = item.series.label;
previousPoint = item.dataIndex;
$("#tooltip").remove();
else {
$("#tooltip").remove();
previousPoint = null;
+ previousLabel = null;
}
});
$('#dmg-graph').bind("plothover", function (event, pos, item) {
if (item) {
- if (previousPoint != item.dataIndex) {
+ if ((previousLabel != item.series.label) || (previousPoint != item.dataIndex)) {
previousPoint = item.dataIndex;
+ previousLabel = item.series.label;
$("#tooltip").remove();
var x = item.datapoint[0].toFixed(2),
else {
$("#tooltip").remove();
previousPoint = null;
+ previousLabel = null;
}
});
dataType: 'json',
success: plot_dmg_graph
});
-
-
})
</script>
% endif
% else:
<div class="row">
- <div class="span8">
+ <div class="span12">
<h2>${player.nick_html_colors()|n}</h2>
+ </div>
+</div>
+
+<div class="row">
+ <div class="span6">
+ <p>
+ Member Since: <small>${player.create_dt.strftime('%m/%d/%Y at %I:%M %p')} </small><br />
+
+ Last Seen: <small><span class="abstime" data-epoch="${recent_games[0][1].epoch()}" title="${recent_games[0][1].create_dt.strftime('%a, %d %b %Y %H:%M:%S UTC')}">${recent_games[0][1].fuzzy_date()}</span> </small><br />
+
+ Playing Time: <small>${total_stats['alivetime']} </small><br />
+
+ <% games_breakdown_str = ', '.join(["{0} {1}".format(ng, gt) for (gt, ng) in games_breakdown]) %>
+ Games Played: <small>${total_games} (${games_breakdown_str})</small><br />
+
+ % if fav_map is not None:
+ Favorite Map: <small><a href="${request.route_url('map_info', id=fav_map['id'])}" title="view map info">${fav_map['name']}</a></small><br />
+ % endif
+ </p>
+ </div>
+ <div class="span6">
<p>
- Member Since: <small>${player.create_dt.strftime('%m/%d/%Y at %I:%M %p')} </small><br />
- Last Seen: <small>${recent_games[0][1].fuzzy_date()} </small><br />
- Playing Time: <small>${total_stats['alivetime']} </small><br />
% if total_games > 0 and total_stats['wins'] is not None:
Win Percentage: <small>${round(float(total_stats['wins'])/total_games * 100, 2)}% (${total_stats['wins']} wins, ${total_games - total_stats['wins']} losses) </small><br />
% endif
+
% if total_stats['kills'] > 0 and total_stats['deaths'] > 0:
Kill Ratio: <small>${round(float(total_stats['kills'])/total_stats['deaths'], 3)} (${total_stats['kills']} kills, ${total_stats['deaths']} deaths) </small><br />
% endif
- <% games_breakdown_str = ', '.join(["{0} {1}".format(ng, gt) for (gt, ng) in games_breakdown]) %>
- Games Played: <small>${total_games} (${games_breakdown_str})</small><br />
+
% if elos_display is not None and len(elos_display) > 0:
Elo:
<small>${', '.join(elos_display)} </small>
<br />
%if '*' in ', '.join(elos_display):
- <small><i>*preliminary Elo</i></small>
+ <small><i>*preliminary Elo</i></small><br />
%endif
% endif
+
+ % if ranks_display != '':
+ Ranks: <small>${ranks_display}</small><br />
+ % endif
</p>
</div>
</div>
% endif
% endif
</td>
- <td>${game.fuzzy_date()}</td>
+ <td><span class="abstime" data-epoch="${game.epoch()}" title="${game.create_dt.strftime('%a, %d %b %Y %H:%M:%S UTC')}">${game.fuzzy_date()}</span></td>
</tr>
% endfor
</tbody>