forked from phaserjs/phaser
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
1.1.1 release with fix for Phaser.AUTO and a new text example.
- Loading branch information
1 parent
2787ed1
commit 9261160
Showing
9 changed files
with
63 additions
and
37 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
// Example created by Arlefreak (https://github.com/Arlefreak) | ||
|
||
var game = new Phaser.Game(800, 600, Phaser.CANVAS, 'phaser-example', { create: create, update: update }); | ||
|
||
var text; | ||
var count; | ||
|
||
function create() { | ||
|
||
count = 0; | ||
|
||
text = game.add.text(game.world.centerX, game.world.centerY, "- You have clicked -\n0 times !", { | ||
font: "65px Arial", | ||
fill: "#ff0044", | ||
align: "center" | ||
}); | ||
|
||
text.anchor.setTo(0.5, 0.5); | ||
|
||
} | ||
|
||
function update() { | ||
|
||
game.input.onDown.addOnce(updateText, this); | ||
|
||
} | ||
|
||
|
||
function updateText() { | ||
|
||
count++; | ||
|
||
text.setText("- You have clicked -\n" + count + " times !"); | ||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters