-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathindex.html
104 lines (104 loc) · 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
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
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>The Good Diver - JavaScript Game developed by Oscar Gonzalez</title>
<!-- load styles-->
<link rel="stylesheet" href="./styles/reset.css" />
<link rel="stylesheet" href="./styles/styles.css" />
</head>
<body>
<!-- displayer -->
<div id="container">
<section id="displayer">
<div>
<h3 id="score">SCORE:</h3>
</div>
<div>
<h3 id="level">LEVEL:</h3>
</div>
<div>
<h3 id="health">HEALTH:</h3>
</div>
<div>
<h3 id="trash">OCEAN TRASH:</h3>
</div>
</section>
<!-- message boxes -->
<section class="messageBox" id="startBox">
<h2>WELCOME</h2>
<p>
Your next mission is to collect as much trash from the ocean as
possible. <br />
But beware of sharks!<br /><br />Use the arrow keys to move around.
Good luck!
</p>
<div class="flex-row">
<img src="./resources/images/keys.png" alt="keys" />
<button class="btn-24" onclick="playGame()">PLAY</button>
</div>
</section>
<section class="messageBox" id="gameOver">
<div class="flex-row">
<img src="./resources/images/shark-winner.png" alt="shark" />
<div>
<h2>GAME OVER</h2>
<p>
Oops! The sharks were hungry...<br />
Please try again, the ocean needs you :)
</p>
<button class="btn-24" onclick="tryAgain()">TRY AGAIN</button>
</div>
</div>
</section>
<!-- game elements -->
<div id="game-board">
<h1 id="logo">The Good Diver</h1>
<div class="controls">
<img
class="arrow-up"
width="40"
src="./resources/images/arrow-up.png"
alt="arrow up"
/>
<div class="flex-row">
<img
class="arrow-left"
width="40"
src="./resources/images/arrow-left.png"
alt="arrow left"
/>
<img
class="arrow-down"
width="40"
src="./resources/images/arrow-down.png"
alt="arrow down"
/>
<img
class="arrow-right"
width="40"
src="./resources/images/arrow-right.png"
alt="arrow right"
/>
</div>
</div>
</div>
</div>
<footer>
<p>
Made with 🤍 by
<a
href="http://oscargonzalez.dev"
target="_blank"
rel="noopener noreferrer"
>Oscar Gonzalez</a
>
</p>
</footer>
<!-- load JavaScript code -->
<script src="./src/logic.js"></script>
<script src="./src/index.js"></script>
</body>
</html>