BlueGit

blue-star speeltuin

Files

speeltuin / src / game.js

game.js

pwd, arrow, looping
timfa Tim · pushed by timfa · 4 years ago
75e64be7 History
game.js 382 B Download Raw
1console.log("Game started!");
2window.onload = function()
3{
4 var game = new Game();
5
6 var scene = new Scene(0, 0, 5, 5, true);
7 game.activeScenes.push(scene);
8
9 game.images =
10 {
11 arrow: new image("images/arrow.png")
12 }
13
14 requestAnimationFrame(function()
15 {
16 game.update();
17 })
18
19 scene.addObject(new Arrow(50, 50, game.images.arrow, 0));
20}