KelvinSP Posted January 13, 2017 Share Posted January 13, 2017 I am trying to run the following example on my machine:https://gamemechanicexplorer.com/#lightning-5 The effect works but the thunder is not showed. I'm getting this error from the browser console: Uncaught TypeError: this.game.math.chanceRoll is not a function In my structure I have the assets folder with all images, the main.js file with the game logic, the index.html and the phaser.min.js file. Note: I'm very newbie on Phaser, then please explain to me what is happen and what can I do. Thanks Link to comment Share on other sites More sharing options...
samme Posted January 14, 2017 Share Posted January 14, 2017 chanceRoll is in Phaser.Utils.chanceRoll() now. The example uses an older Phaser. Link to comment Share on other sites More sharing options...
KelvinSP Posted January 14, 2017 Author Share Posted January 14, 2017 Thank you so much. Changing this.game.math.chanceRoll to Phaser.Utils.chanceRoll() worked. Link to comment Share on other sites More sharing options...
Recommended Posts