Skip to content

marcelabpetroli/js-project-pig-game

Folders and files

NameName
Last commit message
Last commit date

Latest commit

ย 

History

5 Commits
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 

Repository files navigation

Pig Game

This is a project created by Jonas Schmedtmann for his course 'The Complete JavaScript Course 2023: From Zero to Expert!' in the UDEMY platform.

DEMO

In this game two players take turns rolling the dice to win points, the winner is the one who reaches 100 points first. If the number is different than 1 they can keep rolling and adding points, and can chose to hold the current points. Though if they roll a 1 they automatically lose their turn as well as their current points.

demo

Goals for this project

  • Review class manipulation with JS;
  • Reinforce conditionals;
  • Learn how to switch active player by using template literal to build class names;
  • Reinforce DRY principal;