mirror of
https://github.com/photonstorm/phaser
synced 2024-12-21 10:33:35 +00:00
29 lines
620 B
JavaScript
29 lines
620 B
JavaScript
|
var TestGame = {};
|
||
|
|
||
|
TestGame.Preloader = function (game) {
|
||
|
|
||
|
this.game = game;
|
||
|
|
||
|
};
|
||
|
|
||
|
TestGame.Preloader.prototype = {
|
||
|
|
||
|
preload: function () {
|
||
|
|
||
|
this.game.load.image('nocooper', '../assets/pics/1984-nocooper-space.png');
|
||
|
this.game.load.image('touhou', '../assets/pics/aya_touhou_teng_soldier.png');
|
||
|
this.game.load.image('cougar', '../assets/pics/cougar_ihsf.png');
|
||
|
this.game.load.spritesheet('button', '../assets/buttons/button_sprite_sheet.png', 193, 71);
|
||
|
|
||
|
},
|
||
|
|
||
|
create: function () {
|
||
|
|
||
|
console.log('Preloade finished, lets go to the main menu automatically');
|
||
|
|
||
|
this.game.state.start('mainmenu');
|
||
|
|
||
|
}
|
||
|
|
||
|
}
|