yeah, it works

This commit is contained in:
Tyrel Souza 2016-04-06 23:51:10 -04:00
parent 4e74e758d3
commit 2783c8c294
7 changed files with 26 additions and 3 deletions

BIN
assets/blue.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 16 KiB

BIN
assets/green.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 15 KiB

BIN
assets/grey.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 17 KiB

BIN
assets/pink.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 17 KiB

View File

@ -2,11 +2,10 @@
<html> <html>
<head> <head>
<meta charset="utf-8"> <meta charset="utf-8">
<title>Click of the Titans</title> <title>Click of the Aliens!</title>
<style>body {margin: 0; padding: 0;}</style> <style>body {margin: 0; padding: 0;}</style>
<script src="lib/phaser.min.js"></script> <script src="lib/phaser.min.js"></script>
<script src="src/game.js"></script> <script src="src/game.js"></script>
</head> </head>
<body> <body>

1
lib/phaser.map Normal file

File diff suppressed because one or more lines are too long

View File

@ -0,0 +1,23 @@
window.onload = function() {
var game = new Phaser.Game(
800,
800,
Phaser.AUTO,
'',
{ preload: preload, create: create });
function preload(){
game.load.image('pink', 'assets/pink.png');
game.load.image('green', 'assets/green.png');
game.load.image('grey', 'assets/grey.png');
game.load.image('blue', 'assets/blue.png');
console.log("preload");
}
function create(){
var alienSprite = game.add.sprite(450, 290, 'pink');
console.log(alienSprite);
alienSprite.anchor.setTo(0.5, 0.5);
}
};