mirror of
https://github.com/wassname/phaser.git
synced 2026-10-03 12:42:08 +08:00
Group now extends PIXI.DisplayObjectContainer, rather than owning a _container property, which makes life a whole lot easier re: nesting.
This commit is contained in:
1 parent
9737710200
commit
4cfce8b4d2
89 files changed
+1176
-1521
No files matched your search
@@ -32,7 +32,7 @@
|
||||
|
||||
function dirToArray($dir) {
|
||||
|
||||
$ignore = array('.', '..', '_site', 'assets', 'states', 'book', 'filters');
|
||||
$ignore = array('.', '..', '_site', 'assets', 'states', 'book', 'filters', 'misc');
|
||||
$result = array();
|
||||
$root = scandir($dir);
|
||||
$dirs = array_diff($root, $ignore);
|
||||
|
||||
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
@@ -0,0 +1,45 @@
|
||||
|
||||
var game = new Phaser.Game(800, 600, Phaser.AUTO, 'phaser-example', { preload: preload, create: create, update: update, render: render });
|
||||
|
||||
function preload() {
|
||||
|
||||
game.load.image('pic', 'assets/pics/backscroll.png');
|
||||
|
||||
}
|
||||
|
||||
var sprite;
|
||||
var sprite2;
|
||||
var g;
|
||||
|
||||
function create() {
|
||||
|
||||
sprite = game.add.sprite(0, 0, 'pic');
|
||||
|
||||
g = game.add.group();
|
||||
|
||||
g.create(0, 0, 'pic');
|
||||
|
||||
g.y = 200;
|
||||
g.rotation = 0.1;
|
||||
|
||||
// sprite2 = game.add.sprite(0, 300, 'pic');
|
||||
|
||||
game.input.onDown.add(tint, this);
|
||||
|
||||
}
|
||||
|
||||
function tint() {
|
||||
|
||||
sprite.tint = Math.random() * 0xFFFFFF;
|
||||
// sprite2.tint = Math.random() * 0xFFFFFF;
|
||||
|
||||
}
|
||||
|
||||
function update() {
|
||||
|
||||
|
||||
}
|
||||
|
||||
function render() {
|
||||
|
||||
}
|
||||
Reference in new issue
Block a user