phaser/wip/phaser tests/particles/graphic emitter.js
2013-09-13 16:24:01 +01:00

14 lines
487 B
JavaScript

/// <reference path="../../Phaser/Game.ts" />
(function () {
var myGame = new Phaser.Game(this, 'game', 800, 600, init, create);
var emitter;
function init() {
myGame.loader.addImageFile('jet', 'assets/sprites/jets.png');
myGame.loader.load();
}
function create() {
emitter = myGame.add.emitter(myGame.stage.centerX, myGame.stage.centerY);
emitter.makeParticles('jet', 50, false, 0);
emitter.start(false, 10, 0.1);
}
})();