-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathindex2.html
46 lines (40 loc) · 952 Bytes
/
index2.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
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8" />
<meta name="viewport"
content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no, target-densitydpi=device-dpi"/>
<style>
html, body {
overflow: hidden;
width: 100%;
height: 100%;
margin:0;
padding:0;
border: 0;
}
</style>
<script src="js/crafty.js"></script>
<!-- scenes -->
<script src="js/scenes/battlefieldScene.js"></script>
<script src="js/scenes/loadingScene.js"></script>
<script>
window.onload = function() {
// Init crafty in full screen
Crafty.init();
// Init canvas
Crafty.canvas.init();
//define required resource
resource = [];
resource.requiredImages = ['ball.png']
//setup scenes
Crafty.scene("loading", loadingScene);
Crafty.scene("battlefield", battlefieldScene);
// Start the "loading" scene
Crafty.scene("loading");
};
</script>
</head>
<body>
</body>
</html>