-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.html
72 lines (60 loc) · 2.3 KB
/
index.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
<!DOCTYPE html>
<html>
<head>
<meta charset='utf-8'>
<meta http-equiv="X-UA-Compatible" content="chrome=1">
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
<title>N E W - M I S S I L E - C O M M A N D</title>
<link href="https://unpkg.com/tailwindcss@^1.0/dist/tailwind.min.css" rel="stylesheet">
<style>
html, body {
width: 100%;
height: 100%;
margin: 0;
background: #000;
}
.main{
justify-content: space-between;
}
</style>
</head>
<body>
<div class="fixed w-full text-white main">
<p>Score: <span id="scoreEl"></span> </p>
<p>Level: <span id="levelEl"></span> </p>
<div class="flex flex-column main">
<button class="bg-blue-500 text-white px-2 py-1 rounded-full" id="pauseBtn">PAUSE</button>
</div>
<div class="flex flex-column main">
<button class="bg-orange-500 text-white px-2 py-1 rounded-full" id="autoBtn">MODE</button>
</div>
</div>
<div class="fixed inset-0 flex items-center justify-center" id="modalEl">
<div class="bg-white max-w-md w-full p-6 text-center">
<h1 class="text-4xl font-bold leading-none" id="scoreBigEl">0</h1>
<p class="text-sm text-gray-700 mb-4">Points</p>
<div>
<button class="bg-blue-500 text-white w-full py-3 rounded-full" id="gameBtn">Start game</button>
</div>
</div>
</div>
<div class="fixed inset-0 flex items-center justify-center" id="modalMenu">
<div class="bg-white max-w-md w-full p-6 text-center">
<h1 class="text-4xl font-bold leading-none">Missile Command</h1>
<h2 class="text-2xl font-bold leading-none">Defend cities</h2>
<br/>
<div>
<button class="bg-blue-500 text-white w-full py-3 rounded-full" id="resumeBtn">Resume game</button>
</div>
</div>
</div>
<canvas id="game-canvas" width="200" height="100" style="border:1px solid #d3d3d3;">
Your browser does not support the HTML canvas tag.</canvas>
</body>
<script src="city.js"></script>
<script src="asteroid.js"></script>
<script src="explosion.js"></script>
<script src="missile.js"></script>
<script src="inputs.js"></script>
<script src="app.js"></script>
</html>