-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.html
51 lines (50 loc) · 1.72 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
<html>
<head>
<title>A Multiplayer Game</title>
<style>
canvas {
width: 800px;
height: 600px;
border: 5px solid black;
}
</style>
<script src="/socket.io/socket.io.js"></script>
</head>
<body>
<canvas id="canvas"></canvas>
<div id="upgrades">
<table cellspacing="5" cellpadding="5" border="1">
<tr>
<th>Points</th><th>Units Alive</th><th></th><th>Name</th>
</tr>
<tr>
<td id="points">0</td><td id="units">0</td><td></td><td><input type="text" id="name" onchange="nameupdate(this)"></input></td>
</tr>
<tr>
<th>Ability</th><th>Level</th><th>Upgrade Cost</th><th></th>
</tr>
<tr>
<td>Attack</td><td id="attacklevel">0</td><td id="attackcost">0</td><td><button onclick="upgrade('attack')">Upgrade</button></td>
</tr>
<tr>
<td>Defence</td><td id="defencelevel">0</td><td id="defencecost">0</td><td><button onclick="upgrade('defence')">Upgrade</button></td>
</tr>
<tr>
<td>Health</td><td id="healthlevel">0</td><td id="healthcost">0</td><td><button onclick="upgrade('health')">Upgrade</button></td>
</tr>
<tr>
<td>Speed</td><td id="speedlevel">0</td><td id="speedcost">0</td><td><button onclick="upgrade('speed')">Upgrade</button></td>
</tr>
<tr>
<td>Tracking</td><td id="trackinglevel">0</td><td id="trackingcost">0</td><td><button onclick="upgrade('tracking')">Upgrade</button></td>
</tr>
<tr>
<td>Replication</td><td id="replicationlevel">0</td><td id="replicationcost">0</td><td><button onclick="upgrade('replication')">Upgrade</button></td>
</tr>
</table>
<table cellspacing="5" cellpadding="5" border="1" id="leaderboard">
</table>
</div>
</body>
<script src="/static/game.js"></script>
</html>