After the first three weeks of the course, the instructors told us to make a game using pure vanilla JavaScript in order to use all we have learned.
The goal of the game is to collect 100 coins, as many stars as possible and try to not lose too many lives (taking mushrooms), in order to save Princess Peach.
- Download or clone the Github repo
- Run
yarn install
ornpm install
in the terminal to install all the dependencies - Run
gulp
in the terminal to compile the source code and open in the browser
To create this project I used the following technologies:
- HTML5
- SCSS
- JavaScript (ECMAScript 6)
- jQuery
- Gulp
- Yarn
The big challenge I had with this project was making the character caught the coins and determinate when the coins hit the floor.
I did solve that using a collision function dropCoins
which, based on the character height, the coins height and the grid height, was able to determinate when the coins did hit the floor or the character.
I cant believe how much I have learnt in such a short space of time, JavaScript in particular. It has been a brilliant opportunity to put my learning into practice and build my confidence in my new skillset.
There are few improvements that I would love to add.
- Improve the code and fixing the bugs.
- Store the player's score using LocalStorage.
- Improve the UI which is not perfect at the moment.