Playable demo is available here.
Hi folks, this is my approach to the tutorial from this Phaser 3 introduction tutorial.
I wanted to write it in complete typescript, with correct types and fast building speeds. That's the reason why I use Vite for instant server and builds. I also added some bonus codes, check them out at the bottom!
If you are starting with Phaser 3 from scratch, then I recommend reading the code from the first commit up to the last one.
Run development with instant reload in the browser on localhost:3000
yarn dev
Run build. It creates a dist/
folder, that you can serve on your website.
yarn build
Run server from the created build
yarn preview
- Part 1 - Introduction
- Part 2 - Loading Assets
- Part 3+4 - World Building and Platforms
- Part 5 - The Player
- Part 6 - Adding Physics
- Part 7 - Controlling the player with the keyboard
- Part 8 - Stardust
- Part 9 - A score to settle
- Part 10 - Bouncing Bombs
- Bonus 0 - Refactor our scene into Game Objects
- Bonus 1 - Add running with shift key
- Bonus 2 - Add a coin sound