-
Notifications
You must be signed in to change notification settings - Fork 1
/
index.html
180 lines (179 loc) · 9.81 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
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
<!DOCTYPE html>
<html>
<head>
<!-- Global site tag (gtag.js) - Google Analytics -->
<script async src="https://www.googletagmanager.com/gtag/js?id=UA-162255615-1"></script>
<script>
window.dataLayer = window.dataLayer || [];
function gtag(){dataLayer.push(arguments);}
gtag('js', new Date());
gtag('config', 'UA-162255615-1');
</script>
<link href="https://fonts.googleapis.com/css?family=Concert+One|Nunito+Sans:400,700|Ubuntu:400,700&display=swap" rel="stylesheet">
<link rel="stylesheet" type="text/css" href="game.css">
</head>
<body>
<div class="overlay-container" id="overlay-container">
<div class="overlay" id="overlay"></div>
</div>
<div class="game-starter" id="game-starter">
<div class="game_start_head"><div>Pocket</div><div>Tanks</div></div>
<div class="game_start_canon"><img src="images/canon.svg"/></div>
<div class="game_start_tank"><img src="images/tank_main.png" width="300" height="170"/></div>
<div class="game_start_option">
<div>
<button class="start_buttons" id="start_game" onclick="fill_player_details()">Start Game</button>
<!--<button class="start_buttons" id="option_game" onclick="displayOptions()">Options</button>-->
<button class="start_buttons" id="instructions_game" onclick="displayInstructions()">Instructions</button>
</div>
</div>
</div>
<div class="fill_player_details" id="fill_player_details">
<button class="close" onclick="displayStart()">X</button>
<div class="player_details_get">
<div class="player_det_head">
<span id="name_head_1">Player 1</span>
</div>
<div class="input_container">
<label for="player_name_1" class="player_det_label">Name: </label>
<input id = "player_name_1" class="player_det_name_in" type="text" placeholder="Enter player 1 name" value="Player 1" maxlength="16">
</div>
<div class="all_radio_container">
<div class="tank_color_text">Select tank color: </div>
<div class="color_container">
<label class="radio_container">
<input type="radio" name="radio1" class="radio_input" value="blue">
<span class="checkmark blue"></span>
</label>
<label class="radio_container">
<input type="radio" checked="checked" name="radio1" class="radio_input" value="green">
<span class="checkmark green"></span>
</label>
<label class="radio_container">
<input type="radio" name="radio1" class="radio_input" value="red">
<span class="checkmark red"></span>
</label>
<label class="radio_container">
<input type="radio" name="radio1" class="radio_input" value="yellow">
<span class="checkmark yellow"></span>
</label>
</div>
</div>
</div>
<div class="player_details_get">
<div class="player_det_head">
<span id="name_head_2">Player 2</span>
</div>
<div class="input_container">
<label for="player_name_2" class="player_det_label">Name: </label>
<input id = "player_name_2" class="player_det_name_in" type="text" placeholder="Enter player 2 name" value="Player 2" maxlength="16">
</div>
<div class="all_radio_container">
<div class="tank_color_text">Select tank color: </div>
<div class="color_container">
<label class="radio_container">
<input type="radio" checked="checked" name="radio2" class="radio_input" value="blue">
<span class="checkmark blue"></span>
</label>
<label class="radio_container">
<input type="radio" name="radio2" class="radio_input" value="green">
<span class="checkmark green"></span>
</label>
<label class="radio_container">
<input type="radio" name="radio2" class="radio_input" value="red">
<span class="checkmark red"></span>
</label>
<label class="radio_container">
<input type="radio" name="radio2" class="radio_input" value="yellow">
<span class="checkmark yellow"></span>
</label>
</div>
</div>
<div class="next_weapon"><button id="display_weapon" class="button_next"onclick="display_weapon()">Next</button></div>
</div>
</div>
<div class="weapon_select" id="weapon_select">
<button class="right close " onclick="displayStart()">X</button>
<div class="player1_weapons">
<div class="player_det_head">
<span id="weapon_player1_name">Player 1</span>
</div>
<div class="weapon_name_container" id="weapon_name_1"></div>
<div><button onclick="fill_player_details()" class="btn"> Back</button></div>
</div>
<div class="weapon_list">
<div class="weapon_list_head">
<span class="player_det_head">Select Weapons</span>
<span id="current_weapon_selector" class="current_selector"></span>
</div>
<div class="weapon_list_container" id="weapon_list_container">
</div>
</div>
<div class="player2_weapons">
<div class="player_det_head">
<span id="weapon_player2_name">Player 2</span>
</div>
<div class="weapon_name_container" id="weapon_name_2"></div>
<div><button onclick="displayGame()" class="btn">Start Game</button></div>
</div>
</div>
<div class="game-wrapper" id="game-wrapper">
<button class="close super_button" onclick="displayStart()">X</button>
<div id="canvas-wrapper" class="canvas-wrapper"></div>
<div class="player_details">
<div class="input-container">
<label for="tank1_power">Power</label>
<input id = "tank1_power" class="range" type="range" placeholder="Enter tank 1 power" value=50>
<span class="range_display" id="range_1_1"></span>
</div>
<div class="input-container">
<label for="tank1_angle">Angle</label>
<input id = "tank1_angle" class="range" type="range" placeholder="Enter tank 1 angle" value=45 min="0" max="90">
<span class="range_display" id="range_1_2"></span>
</div>
<div class="bottom_container">
<div class="img_weapon_container">
<select id ="player1_options" class="select_btn">
</select>
<div class="show_weapon_container"><img class="show_weapon" id="show_weapon_1" src="images/missile.svg"/></div>
</div>
<button id="button1" class="fire-button" onclick="fire(0)" >Fire</button>
</div>
</div>
<div class="player_details">
<div class="input-container">
<label for="tank2_power">Power</label>
<input id = "tank2_power" class="range" type="range" placeholder="Enter tank 2 power" value=50>
<span class="range_display" id="range_2_1"></span>
</div>
<div class="input-container">
<label for="tank2_angle">Angle</label>
<input id = "tank2_angle" class="range" type="range" placeholder="Enter tank 1 angle" value=45 min="0" max="90">
<span class="range_display" id="range_2_2"></span>
</div>
<div class="bottom_container">
<div class="img_weapon_container">
<select id ="player2_options" class="select_btn">
</select>
<div class="show_weapon_container"><img class="show_weapon" id="show_weapon_2" src="images/missile.svg"/></div>
</div>
<button id="button2" class="fire-button" onclick="" >Fire</button>
</div>
</div>
</div>
<div id="instructions" class="instructions">
<button class="close" onclick="displayStart()">X</button>
<div class="instructions_head">Instructions</div>
<div class="instructions_body">
<ul>
<li>Pocket tanks is a 2 player game.</li>
<li>Select your tank color and weapons. Each weapon has different power</li>
<li>Adjust your power and angle to hit the enemy tank. Take care of the wind.</li>
<li>Player with most point till the end of weapons win.</li>
</ul>
</div>
</div>
<div class="loading" id="loading">Loading</div>
<script src="game_core.js"></script>
</body>
</html>