-
Notifications
You must be signed in to change notification settings - Fork 4
/
Copy pathgame.html
111 lines (101 loc) · 6.92 KB
/
game.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
<!DOCTYPE html>
<html>
<head>
<title>Rocket League Analytics</title>
<meta name="description" content="Detailed stats about my Rocket League games with friends :)" />
<meta name="keywords" content="sports, analytics, PC Gaming, Rocket League, machine learning, optimization, modeling" />
<meta name="author" content="Sertalp B. Cay (sertalpbilal[at]hotmail[dot]com)" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<link href="https://cdn.jsdelivr.net/npm/[email protected]/dist/css/bootstrap.min.css" rel="stylesheet" integrity="sha384-+0n0xVW2eSR5OomGNYDnhzAbDsOXxcvSN1TPprVMTNDbiYZCxYbOOl7+AMvyTG2x" crossorigin="anonymous">
<link rel="stylesheet" type="text/css" href="https://cdn.datatables.net/v/bs4/dt-1.10.23/b-1.6.5/b-colvis-1.6.5/b-html5-1.6.5/fc-3.3.2/fh-3.1.7/r-2.2.6/sp-1.2.2/datatables.min.css" />
<script src="https://d3js.org/d3.v6.js"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/d3-interpolate/1.3.0/d3-interpolate.js" integrity="sha512-KcUKnCgVgjA6pyyyN33d5S1IHk9hFUaldkL8BmKvqR+7q9HyZj3jmWJemF6IJuLkcj3biCNzdGgXNPJCjurXnQ==" crossorigin="anonymous"></script>
<script src="https://cdn.jsdelivr.net/npm/@fortawesome/[email protected]/js/fontawesome.min.js" integrity="sha256-TMRxGf3NaZhrxTfD8y/NGiyE4UXBA3udH1l+Co8JDVU=" crossorigin="anonymous"></script>
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/@fortawesome/[email protected]/css/all.min.css" integrity="sha256-rx5u3IdaOCszi7Jb18XD9HSn8bNiEgAqWJbdBvIYYyU=" crossorigin="anonymous">
<link rel="stylesheet" href="static/css/styles.css">
</head>
<body>
<header>
<nav class="navbar navbar-light bg-light">
<div class="container">
<a class="navbar-brand mb-0 h1" href="index.html">Rocket League Analytics</a>
</div>
</nav>
</header>
<main id="app">
<div class="container mb-3">
<div class="row justify-content-center" v-if="!_.isEmpty(navigation)">
<div class="col-2 text-center nav_game">
<a v-if="navigation.prev" :href="'game.html?id='+navigation.prev['Replay ID']"><i class="fas fa-chevron-circle-left"></i></a>
<i class="fas fa-chevron-circle-left" v-else></i>
</div>
<div class="col-8 text-center mb-3">
Game ID: {{ game_id }} </br/>
Date/Time: {{ (new Date(navigation.this_game['StartTime'] * 1000)).toISOString().slice(0,16) }}
</div>
<div class="col-2 text-center nav_game">
<a v-if="navigation.next" :href="'game.html?id='+navigation.next['Replay ID']"><i class="fas fa-chevron-circle-right"></i></a>
<i class="fas fa-chevron-circle-right" v-else></i>
</div>
<div class="col-12 row">
<!-- {{ navigation.this_game }} -->
<div class="col-2 col-sm g-cols" v-for="tag in display_tags">
<div class="d-flex flex-column pl-2 pr-2">
<div class="p-0 g-title text-center">{{ tag }}</div>
<div class="p-0 g-value text-center">{{ navigation.this_game[tag] }}</div>
</div>
</div>
</div>
<div class="col-12 col-md-5 mt-3 mb-3">
<div id="pitch_with_shots">
</div>
</div>
<div class="col-12 col-md-5 mt-3 mb-3">
<div id="xG_timeline">
</div>
</div>
<div class="col-12">
<h5>Shots</h5>
<div class="text-small-mobile">
<table class="table table-sm table-striped table-responsive" id="shot_list">
<thead>
<tr>
<th>Player</th>
<th>Team</th>
<th>Frame</th>
<th>Time</th>
<th>On Target</th>
<th>xG</th>
<th>Goal</th>
<th>Replay</th>
</tr>
</thead>
<tbody>
<tr v-for="shot, idx in shots_combined" v-if="shot.visible" :id="'shot-' + shot['order']" @mouseover="hover_row" @mouseleave="leave_row" :data-target-marker="'marker-' + shot['order']">
<td>{{ shot['shot_taker_name'] }}</td>
<td :style="{'color': shot['team_color']}">{{ shot['team_name'] }}</td>
<td>{{ parseInt(shot['frame']) }}</td>
<td>{{ parseInt(shot['time']) }}</td>
<td>{{ shot['shot'] }}</td>
<td :style="{'background': shot['xg_color']}">{{ parseFloat(shot['xg_info']['xg']).toFixed(3) }}</td>
<td :style="{'background': shot['goal_color']}">{{ shot['goal'] }}</td>
<td>
<a target=_blank class="btn btn-danger pt-0 pb-0 pl-1 pr-1 mlink" role="button" :href="'https://ballchasing.com/replay/' + game_id + '#watch?t=' + shot['sec'] + 's'"><i class="fas fa-video"></i></a>
</td>
</tr>
</tbody>
</table>
</div>
</div>
</div>
</div>
</main>
<script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/3.5.1/jquery.js" integrity="sha512-WNLxfP/8cVYL9sj8Jnp6et0BkubLP31jhTG9vhL/F5uEZmg5wEzKoXp1kJslzPQWwPT1eyMiSxlKCgzHLOTOTQ==" crossorigin="anonymous"></script>
<script src="https://cdn.jsdelivr.net/npm/[email protected]/dist/js/bootstrap.bundle.min.js" integrity="sha384-gtEjrD/SeCtmISkJkNUaaKMoLD0//ElJ19smozuHV6z3Iehds+3Ulb9Bn9Plx0x4" crossorigin="anonymous"></script>
<script src="https://cdn.jsdelivr.net/npm/[email protected]"></script>
<script src="https://cdn.jsdelivr.net/npm/[email protected]/lodash.min.js" integrity="sha256-ur/YlHMU96MxHEsy3fHGszZHas7NzH4RQlD4tDVvFhw=" crossorigin="anonymous"></script>
<script type="text/javascript" src="https://cdn.datatables.net/v/bs4/dt-1.10.23/b-1.6.5/b-colvis-1.6.5/b-html5-1.6.5/fc-3.3.2/fh-3.1.7/r-2.2.6/sp-1.2.2/datatables.min.js"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/jquery-csv/1.0.21/jquery.csv.min.js" integrity="sha512-Y8iWYJDo6HiTo5xtml1g4QqHtl/PO1w+dmUpQfQSOTqKNsMhExfyPN2ncNAe9JuJUSKzwK/b6oaNPop4MXzkwg==" crossorigin="anonymous" referrerpolicy="no-referrer"></script>
<script src="static/js/game.js"></script>
</body>
</html>