Skip to main content

excaliburjs logoTesting Your Game

There are two ways you can test your game as you develop it:

  • npm run watch:live
    • Starts a local development server and opens your game in a browser with hot-reloading enabled
  • https://xelly.games/utility
    • Requires manual upload of dist/bundle.js whenever you change it, but may be useful when you are testing your game with browser devtools

Using npm run watch:live

If you created your package.json per these instructions, then you can run:

$ npm run watch:live

This will open a browser window with your game running in it. The game will automatically reload whenever you make changes to your game's source code.

Using xelly.games/utility

  1. While actively coding, build your game in "watch mode":
$ npm run watch
  1. As you make code changes, the game will automatically rebuild dist/bundle.js. You can upload this file to xelly.games/utility to test your changes out as you develop. (You will have to re-upload the bundle.js each time you want test new changes. Note that the utility tool is a local-only tool; your game is not uploaded by this tool to xelly.games or anywhere else.)

  2. When your game is live and running on a social feed, console.log is disabled, but the utility tool will allow logs to the console which may be helpful for debugging your game as you develop it.

  3. Once you're happy with your game, you can submit it from your profile.