-
Notifications
You must be signed in to change notification settings - Fork 0
/
tournaments - Copy.html
312 lines (282 loc) · 15.2 KB
/
tournaments - Copy.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
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
<!-- Modifications copyright (C) 2019 Kamil Szurant -->
<!DOCTYPE html>
<html lang = "en">
<head>
<title>Beat Aim - Rhythm Shooter</title>
<meta charset="UTF-8">
<meta name="description"
content="Beat Aim - rhythm game designed for FPS players with ai generated maps. Makes improving your aim incredibly fun while listening to your favorite songs.">
<meta name="keywords" content="beat aim, beat,aim,beataim,shooter,trainer,practice,rhythm,3d,ai,kamyker">
<meta name="author" content="Kamil Szurant">
<meta property="og:title" content="Beat Aim">
<meta property="og:type" content="website">
<meta property="og:image" content="https://beataim.com/meta-image.jpg">
<meta property="og:url" content="https://beataim.com">
<meta property="og:description"
content="Rhythm game designed for FPS players with ai generated maps. Makes improving your aim incredibly fun while listening to your favorite songs.">
<meta name="twitter:card" content="summary_large_image">
<meta name="twitter:site" content="@beat_aim">
<meta name="twitter:creator" content="@kamyker">
<meta name="twitter:title" content="Beat Aim">
<meta name="twitter:description"
content="Rhythm game designed for FPS players with ai generated maps. Makes improving your aim incredibly fun while listening to your favorite songs.">
<meta name="twitter:image" content="https://beataim.com/meta-image.jpg">
<meta name="viewport" content="width=device-width, initial-scale=1">
<link href="https://fonts.googleapis.com/css?family=Open+Sans" rel="stylesheet">
<!-- DEVELOPMENT FILES
<link rel="stylesheet" type="text/css" href="../dist/css/meshki.min.css">
<link rel="stylesheet" type="text/css" href="../dist/plugins/meshki-extra-button-colors.min.css">
<script type="text/javascript" src="../dist/js/meshki.min.js"></script>
DEVELOPMENT FILES -->
<!-- PRODUCTION FILES -->
<link rel="stylesheet" type="text/css" href="/cdn/meshki.min.css">
<link rel="stylesheet" type="text/css" href="/cdn/meshki-extra-button-colors.min.css">
<script type="text/javascript" src="/cdn/meshki.min.js"></script>
<!-- PRODUCTION FILES -->
<link rel="stylesheet" type="text/css" href="/custom.css">
<link rel="stylesheet" type="text/css" href="/cdn/font-awesome.min.css">
<!--[if lt IE 9]>
<script src="https://cdnjs.cloudflare.com/ajax/libs/respond.js/1.4.2/respond.min.js"></script>
<![endif]-->
<link rel="shortcut icon" href="/favicon.ico" type="image/x-icon" />
<link rel="stylesheet" href="/cdn/prism.min.css">
<link rel="stylesheet" href="/cdn/prism-okaidia.min.css">
<link href="https://fonts.googleapis.com/css?family=Muli&display=swap" rel="stylesheet">
<link href="https://fonts.googleapis.com/css?family=Cinzel&display=swap" rel="stylesheet">
<link href="https://emoji-css.afeld.me/emoji.css" rel="stylesheet">
<script type="text/javascript" src="/PlayFabClientApi.js"></script>
<script type="text/javascript" src="/PlayFabCustom.js"></script>
<script type="text/javascript" src="/AzAzAz.js"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/json2html/1.3.0/json2html.min.js"></script>
<script src="https://d3js.org/d3-dsv.v1.min.js"></script>
</head>
<body class="">
<div class="sidenav push">
<a href="javascript:void(0);" class="sidenav-close-button" onclick="meshki.closeSidenav()">×</a>
<a href="index.html">Home</a>
<div class="hide-on-mobile">
<a href="https://discord.gg/2kW27Ez">Discord</a>
<a href="https://twitter.com/beat_aim">Twitter</a>
<a href="https://www.facebook.com/BeatAim/">Facebook</a>
</div>
<!-- <hr class="hide-on-non-mobile"> -->
<div class="hide-on-non-mobile">
<a href="https://store.steampowered.com/newshub/app/1142220" target="_blank"
onclick="meshki.closeSidenav()">News</a>
<a href="/roadmap" onclick="meshki.closeSidenav()">Roadmap</a>
<a href="/esports" onclick="meshki.closeSidenav()">Esports League</a>
<a href="/streamers" onclick="meshki.closeSidenav()">Streamers League</a>
<a href="/top-new-maps" onclick="meshki.closeSidenav()">Mapping League</a>
<a href="/partners" onclick="meshki.closeSidenav()">Partners</a>
<!-- <a href="/referral">Referrals</a> -->
</div>
<hr>
<!-- <button onclick="location.href='https://twitter.com/Meshki_UI'" class="button blue medium"><b></b><i class="fa fa-twitter" aria-hidden="true"></i></button>
<button onclick="location.href='https://www.npmjs.com/package/meshki'" class="button red medium"><b>npm</b></button>
<button onclick="location.href='https://github.com/Borderliner/Meshki'" class="button medium"><b></b><i class="fa fa-github" aria-hidden="true"></i></button> -->
<a href="javascript:void(0)" disabled style="font-size: 1.5rem">Share on:</a>
<div class="share-links">
<a class="fb-share" href="https://www.facebook.com/sharer/sharer.php?u=http://beataim.com/" target="_blank"><i
class="fa fa-facebook-square" aria-hidden="true"></i></a>
<a class="tw-share" href="https://twitter.com/home?status=http://beataim.com/" target="_blank"><i
class="fa fa-twitter-square" aria-hidden="true"></i></a>
<a class="gp-share" href="https://plus.google.com/share?url=http://beataim.com/" target="_blank"><i
class="fa fa-google-plus-square" aria-hidden="true"></i></a>
</div>
</div>
<div class="container">
<div class="nav fixed">
<ul>
<li><a class="logo" href="javascript:void(0);" onclick="meshki.openSidenav()"><i class="fa fa-bars"
aria-hidden="true"></i>Beat Aim</a>
</li>
<!-- <li class="nav-dropdown hide-on-mobile">
<a href="javascript:void(0)" class="nav-dropdown-button">Plugins</a>
<div class="nav-dropdown-content">
<a href="rtl/">RTL Mode (Persian)</a>
<a href="#extra-button-colors">Extra Button Colors</a>
</div>
</li> -->
<div class="hide-on-mobile">
<li><a href="/" target="_blank">Buy</a></li>
<li><a href="https://store.steampowered.com/newshub/app/1142220" target="_blank">News</a></li>
<li><a href="/roadmap">Roadmap</a></li>
<!-- <li><a href="make-account.html">Alpha sign up</a></li> -->
<li><a href="/esports">Esports League</a></li>
<li><a href="/streamers">Streamers League</a></li>
<li><a href="/top-new-maps">Mapping League</a></li>
<!-- <li><a href="redeem-key.html">Redeem alpha key</a></li> -->
<li><a href="/partners">Partners</a></li>
</div>
<!-- <li><a href="https://github.com/Borderliner/Meshki/blob/master/CHANGELOG.md">News</a></li>
<li><a href="https://github.com/Borderliner/Meshki">GitHub</a></li> -->
<!-- <li class="nav-dropdown hide-on-mobile">
<a href="javascript:void(0)" class="nav-dropdown-button">Components</a>
<div class="nav-dropdown-content">
<a href="#buttons-doc">Buttons</a>
<a href="#sidenav-doc">Sidenav</a>
<a href="#navbar-doc">Navbar</a>
<a href="#grid-doc">Grid System</a>
<a href="#form-doc">Forms</a>
<a href="#typography-doc">Typography</a>
<a href="#tables-doc">Tables</a>
<a href="#footer-doc">Footer</a>
</div>
</li> -->
<li class="nav-right">
<a href="https://discord.gg/2kW27Ez" target="_blank" style="padding-top: 12px; padding-right: 22px">
<img src="/imgs/discord-white.png" alt="discord" width="34px" height="38px">
</a>
</li>
<li class="nav-right">
<a href="https://twitter.com/beat_aim" target="_blank">
<img src="/imgs/twitterLogo.png" alt="twitter" width="34px" height="34px">
</a>
</li>
<li class="nav-right">
<a href="https://www.youtube.com/c/BeatAim" target="_blank"style="padding-top: 17px">
<img src="/imgs/youtube.png" alt="facebook" width="34px" height="26px">
</a>
</li>
<!-- <li class="nav-right" style="display:table;">-->
<!-- <a class="right-el-nav" href="https://discord.gg/2kW27Ez" target="_blank">-->
<!-- <img src="/imgs/discord.png" alt="discord" width="38px" height="38px">-->
<!-- </a>-->
<!-- <a class="right-el-nav" href="https://twitter.com/beat_aim" target="_blank">-->
<!-- <img src="/imgs/twitter.png" alt="twitter" width="34px" height="34px">-->
<!-- </a>-->
<!-- <a class="right-el-nav" href="https://www.facebook.com/BeatAim/" target="_blank">-->
<!-- <img src="/imgs/fb.png" alt="facebook" width="34px" height="34px">-->
<!-- </a>-->
<!-- </li>-->
<!-- <li class="nav-right hide-on-tablet">
<script type="text/javascript" src="finder.js"></script>
<input type="text" name="searchbox" id="searchbox" placeholder="Search..."
onkeydown="meshkiUtil.search(this)">
</li>
<li class="nav-right hide-on-tablet"><button class="green" onclick="meshkiUtil.search(true)"><i
class="fa fa-search" aria-hidden="true"></i></button></li> -->
</ul>
</div>
<div class="content">
<div class="row text-center">
<h1>Weekly top players</h1>
<p>The best players across all leaderboards, updated every 10 mins.</p>
</div>
<br>
<script type="text/javascript">
// function shuffleArray(array) {
// for (let i = array.length - 1; i > 0; i--) {
// const j = Math.floor(Math.random() * (i + 1));
// [array[i], array[j]] = [array[j], array[i]];
// }
// }
const userAction = async () => {
let htmlString = '<h4 style="word-spacing: 30px; border-width: 2px;border-style: outset; padding: 10px">';
try {
const response = await fetch(
'https://beataim.herokuapp.com/api/tournaments/getweeklyresults');
//["jwun","XVoIR","Brumor","Drimzi","kamyker2","Saotic","Bloodyjesse"]
topPlayers = await response.json();
for (let index = 0; index < topPlayers.length; index++) {
htmlString += topPlayers[index];
if (index > 0 && index + 1 % 3 === 0)
htmlString += '<br>';
else if (index + 1 < topPlayers.length)
htmlString += ' ';
}
} catch (error) {
htmlString += 'error :(';
console.error(error);
}
htmlString += '</h4>';
var div = document.createElement("div");
div.className = "row text-center";
div.insertAdjacentHTML('beforeend', htmlString);
div.insertAdjacentHTML('beforeend', '<br><h4>Current tournament ends in:</h4>');
div.insertAdjacentHTML('beforeend', '<h2 id="timer"></h2>');
div.insertAdjacentHTML('beforeend', '<br><h4>Prizes:</h4>');
const tournamentsList = await (await fetch("game/tournamentsList.json")).json();
div.insertAdjacentHTML('beforeend', `<h3>${tournamentsList.tournaments[0].prizePerPlayer}</h3>`);
console.log(tournamentsList);
var countDownDate = new Date(tournamentsList.tournaments[0].end).getTime();
// var countDownDate = new Date("Mon 11, 2019 12:00:00").getTime();
var x = setInterval(function () {
var now = new Date().getTime();
var distance = countDownDate - now;
var days = Math.floor(distance / (1000 * 60 * 60 * 24));
var hours = Math.floor((distance % (1000 * 60 * 60 * 24)) / (1000 * 60 * 60));
var minutes = Math.floor((distance % (1000 * 60 * 60)) / (1000 * 60));
var seconds = Math.floor((distance % (1000 * 60)) / 1000);
document.getElementById("timer").innerHTML = days + "d " + hours + "h "
+ minutes + "m " + seconds + "s ";
if (distance < 0) {
clearInterval(x);
document.getElementById("timer").innerHTML = "Ended";
}
}, 1000);
div.insertAdjacentHTML('beforeend', '<br><br><p>Tournaments are currently in development. We plan to make them last 4 days (Thursday - Sunday). Prizing will depend on number of active players.</p>');
document.getElementsByClassName("content")[0].appendChild(div);
}
userAction();
</script>
</div>
<div class="footer " style="font-size: 10px">
<div class="row text-center">
<div class=" four col ">
<span>Created using Meshki by <a href=" https://github.com/Borderliner" target="_blank">Borderliner </a>
</span></div>
<div class=" four col ">
<a href="https://store.steampowered.com/app/1142220/Beat_Aim__Rhythm_Aim_Trainer/" target="_blank"
style="padding: 0px 10px">
<img src="/imgs/steamearly2.png" alt="BeatAimSteam" width="136px" height="22px">
</a>
</div>
<div class="four col">
<span>Few icons by <a href="http://www.freepik.com/" target="_blank">Freepik</a> from <a
href="http://www.flaticon.com/" target="_blank">www.flaticon.com </a></span>
</div>
</div>
</div>
<script type="text/javascript"
src="https://cdnjs.cloudflare.com/ajax/libs/clipboard.js/1.7.1/clipboard.min.js"></script>
<script type="text/javascript">
// var percent_update = function () {
// document.getElementById("percent_value").innerHTML = this.value;
// console.log(this.value);
// };
// document.getElementById("percent").onchange = percent_update;
// document.getElementById("percent").oninput = percent_update;
var clipboard = new Clipboard('.clipboard-btn');
clipboard.on('success', function (e) {
var classArray = e.trigger.className.split(' ');
classArray.splice(classArray.indexOf('blue'), 1);
classArray.push('green');
e.trigger.className = classArray.join(' ');
e.trigger.innerHTML = '<i class="fa fa-check" aria-hidden="true"></i> Copied';
window.setTimeout(function () {
var classArray = e.trigger.className.split(' ');
classArray.splice(classArray.indexOf('green'), 1);
classArray.push('blue');
e.trigger.className = classArray.join(' ');
e.trigger.innerHTML = '<i class="fa fa-clipboard" aria-hidden="true"></i>';
}, 2000);
});
clipboard.on('error', function (e) {
var classArray = e.trigger.className.split(' ');
classArray.splice(classArray.indexOf('blue'), 1);
classArray.push('red');
e.trigger.className = classArray.join(' ');
e.trigger.innerHTML = '<i class="fa fa-exclamation-triangle" aria-hidden="true"></i> Error';
window.setTimeout(function () {
var classArray = e.trigger.className.split(' ');
classArray.splice(classArray.indexOf('red'), 1);
classArray.push('blue');
e.trigger.className = classArray.join(' ');
e.trigger.innerHTML = '<i class="fa fa-clipboard" aria-hidden="true"></i>';
}, 2000);
});
</script>
<script type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/prism/1.6.0/prism.min.js"></script>
</body>
</html>