wareja

retry level button not working

Recommended Posts

hi, I've been using phaser for some time now but am having some issue with my game when I press the restart button.

My game goes into an infinite loop and my player can't jump as high as he used to before. Its like as if gravity increased on the stage. and other objects disappear too like they go all the way down to the screen

Can somebody tell me whats wrong here

  retry: function () {
        //this.clearCurrentState()
        this.levelSong.pause()
        this.winSong.pause()
        this.gameOverSong.pause()
        this.shutdown()
        this.game.state.start('Level2')
    },

  shutdown:function()
{
    this.game.world.removeAll()
},

here is the link to my game (My problem is in level 2):

https://exit-exitar.firebaseapp.com

Edited by wareja
made it more clear

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...

  • Recently Browsing   0 members

    No registered users viewing this page.