forked from jsx/JSX
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathshooting.html
More file actions
45 lines (44 loc) · 1.26 KB
/
Copy pathshooting.html
File metadata and controls
45 lines (44 loc) · 1.26 KB
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
<html>
<head>
<title>Shooting Game in JSX</title>
<meta name="viewport" content="width=device-width,user-scalable=no" />
<meta name="apple-mobile-web-app-capable" content="yes" />
<meta name="apple-mobile-web-app-status-bar-style" content="black-translucent" />
<style>
body {
margin: 0;
}
#scoreboard {
position: absolute;
left: 0;
top: 0;
font-size: 18px;
color: #fff;
text-align: right;
}
</style>
<script src="../jsx.combined.js"></script>
<script src="../assets/js/jsx-browser-platform.js"></script>
<script>
//jsx.enableOptimizations = true;
</script>
<script src="../assets/js/jsx-script-loader.js"></script>
<script type="application/jsx" src="shooting.jsx"></script>
<script src="shooting.js"></script>
<script>
window.addEventListener("load", function(e) {
if(location.hash === "#js") {
_Main.main(["stage", "scoreboard"]);
}
else {
var shooting = JSX.require("shooting.jsx");
shooting._Main.main$AS(["stage", "scoreboard"]);
}
});
</script>
</head>
<body>
<canvas id="stage"></canvas>
<div id="scoreboard">000000000<br/>0 FPS</div>
</body>
<html>