Skip to content

Commit

Permalink
Basic examples.
Browse files Browse the repository at this point in the history
  • Loading branch information
DavidAntliff committed Jul 26, 2015
1 parent bce17af commit 8f10efb
Show file tree
Hide file tree
Showing 8 changed files with 115 additions and 0 deletions.
34 changes: 34 additions & 0 deletions hellophaser/index.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
<!doctype html>
<html>
<head>
<meta charset="UTF-8" />
<title>hello phaser!</title>
<script src="phaser.min.js"></script>
</head>
<body>

<script type="text/javascript">

window.onload = function() {

var game = new Phaser.Game(800, 600, Phaser.AUTO, '', { preload: preload, create: create });

function preload () {

game.load.image('logo', 'phaser.png');

}

function create () {

var logo = game.add.sprite(game.world.centerX, game.world.centerY, 'logo');
logo.anchor.setTo(0.5, 0.5);

}

};

</script>

</body>
</html>
12 changes: 12 additions & 0 deletions hellophaser/phaser.min.js

Large diffs are not rendered by default.

Binary file added hellophaser/phaser.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
18 changes: 18 additions & 0 deletions hellophaser2/hellophaser2.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
window.onload = function() {

var game = new Phaser.Game(800, 600, Phaser.AUTO, '', { preload: preload, create: create });

function preload () {

game.load.image('logo', 'phaser.png');

}

function create () {

var logo = game.add.sprite(game.world.centerX, game.world.centerY, 'logo');
logo.anchor.setTo(0.5, 0.5);

}

};
13 changes: 13 additions & 0 deletions hellophaser2/index.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
<!doctype html>
<html>
<head>
<meta charset="UTF-8" />
<title>hello phaser!</title>
<script src="phaser.min.js"></script>
</head>
<body>

<script type="text/javascript" src="hellophaser2.js"></script>

</body>
</html>
12 changes: 12 additions & 0 deletions hellophaser2/phaser.min.js

Large diffs are not rendered by default.

Binary file added hellophaser2/phaser.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
26 changes: 26 additions & 0 deletions js/phaser.min.js

Large diffs are not rendered by default.

0 comments on commit 8f10efb

Please sign in to comment.