Skip to content

The Pig Game - The objective of the game is to be the first player to reach 100 points. - by Jonas Schmedtmann in "The Complete JavaScript Course: From Zero to Expert!"

License

Notifications You must be signed in to change notification settings

kokenydaniel/Pig-game

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Képernyőfotó 2023-10-08 - 18 53 53 (2)

Pig Dice Game

About The Project

This is an entertaining and funny dice game for 2 players where the goal of the game is to be the first to reach 100 points.

Each turn, the current player rolls a die until they roll a 1 or press "hold" to end their current turn. If the player rolls a 1, the player's turn ends and the player's current points are cleared. If the player rolls any other number, it is added to the current score, after which he can choose to roll again or keep it. If you choose to keep it, your current scores are added to your total score and the round ends.

Have fun!

Built in

  1. JavaScript
  2. HTML5
  3. CSS

What I learned

In this little game, I also learned a lot about the possibilities of javascript, where anything can be achieved with DOM manipulation. It was interesting for me to create a game where you had to build a slightly more complex rule.

Acknowledgment

Thanks to everyone who gives feedback on my solution. It definitely helps you find new ways to code and find easier solutions!

About

The Pig Game - The objective of the game is to be the first player to reach 100 points. - by Jonas Schmedtmann in "The Complete JavaScript Course: From Zero to Expert!"

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published