-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathindex.html
69 lines (68 loc) · 1.73 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
<!DOCTYPE html>
<html>
<head>
<title>Snake Game</title>
<style>
body {
font-family: Arial, sans-serif;
display: flex;
flex-direction: column;
justify-content: center;
align-items: center;
background-color: lightgray
}
#gui {
margin-bottom: 10px;
}
.hidden {
display: none;
}
canvas
</style>
</head>
<body>
<h1>Snake game</h1>
<div id="gui">
<div>
<span>Best Score: <span id="bestScore">0</span></span>
</div>
<div>
<span>Current Score: <span id="currentScore">0</span></span>
</div>
<div id="menuButtons">
<button id="playButton">Play</button>
<button id="exitButton">Exit</button>
</div>
<div id="gameButtons" class="hidden">
<button id="menuButton">Menu</button>
</div>
<div>
<label for="gameMode">Game Mode:</label>
<div id="gameMode">
<label>
<input type="radio" name="gameMode" value="classic" checked />
Classic
</label>
<label>
<input type="radio" name="gameMode" value="noDie" />
No Die
</label>
<label>
<input type="radio" name="gameMode" value="walls" />
Walls
</label>
<label>
<input type="radio" name="gameMode" value="portal" />
Portal
</label>
<label>
<input type="radio" name="gameMode" value="speed" />
Speed
</label>
</div>
</div>
</div>
<script src="https://pixijs.download/release/pixi.js"></script>
<script src="./game.js" type="module"></script>
</body>
</html>