Pig is a simple dice game first described in print by John Scarne in 1945. Players take turns to roll a single die as many times as they wish, adding all roll results to a running total, but losing their gained score for the turn if they roll a 1.
- Clone repository - Go ahead and clone the repository.
- Install packages
npm install
- Run program
npm start
- Server available at http://localhost:1234 by default.
- Have fun!
I built this game for fun and to practice the MVC architecture. You can play the game, but keep in mind that the game is still in development and lacks some features.
-
Stack
- Vanilla JS
- HMTL
- CSS
-
Methodologies
- MVC (Model-View-Controller) Architecture
- Model Bundling with parcel
- Older browser support
- Regenerator runtime
- Core-JS
- Responsive Design - Mobile friendly!
- Play Again
- New Game
If you wish to play again you can reload the browser until the features are implemented.
- Roll Dice: Roll the dice as many times as you wish
- Roll Dice will roll a random 6 sided dice. Each time you roll the dice score will be added to your current score (Unless you land 1).
- If you land 1: Your current score will be nullified and the next player takes turn.
- Hold
- Hold: Hold will add your current score to your total score. The current score will be nullified and then the next player takes turn.
- Winner
- The game goes on until one of the players reaches 100 points.
- You can choose to start the game again if you desire.
- New Game
- Resets the game.
- Made with love by Loreta Krasteva ~