Jump to content

Phaser states


CindySchroer
 Share

Recommended Posts

Hello I need some help with my game. I wanted to work with game states so I've got this code (see attachment)
In boot.js I've got this:
var Game ={};

Game.Boot = function(game){

};

Game.Boot.prototype = {
    init:function(){
        this.input.maxPointers =1;

        this.stage.disableVisibilityChange=true;

    },

    preload:function(){
        this.load.image('preloaderBar', 'assets/meme.jpg');

    },

    create:function(){
        this.state.start('Preloader');
    }
}

Just a simple picture has to come up but when I load my game this error shows up: Uncaught ReferenceError: windows is not defined(…)
Can anyone explain what is happening here? A little step-by-step would help because I'm a beginner. 

Schermafbeelding 2016-11-02 om 18.14.02.png

Link to comment
Share on other sites

 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...