Skip to content

Latest commit

 

History

History
44 lines (29 loc) · 1.5 KB

README.md

File metadata and controls

44 lines (29 loc) · 1.5 KB

Pig Game 🎲

A fun and interactive dice game built with JavaScript, HTML, and CSS! Test your luck and enjoy a friendly competition.

Description

Pig Game is a two-player dice game where players take turns rolling a die to accumulate points. The first player to reach a set score wins the game. However, beware: rolling a 1 will reset your turn score to zero, and it’ll be the other player’s turn!

How to Play

  1. Each player takes turns rolling the dice.
  2. During a turn, the player can roll to add to their current score or hold to add their current score to their total.
  3. If a player rolls a 1, their current turn ends, and they lose any points accumulated during that turn.
  4. The first player to reach the target score (e.g., 100 points) wins the game.

Features

  • Dynamic score tracking
  • Reset option to start a new game
  • Interactive visuals to enhance the gaming experience

Game Interface

Initial Game Screen

Game Interface

Winning Screen

Winning Screen

Installation

To play the game locally:

  1. Clone the repository:
    git clone https://github.com/OrasanuAna/Pig-Game.git
  2. Open index.html in your browser to start playing.

Technologies Used

  • HTML for structuring the content
  • CSS for styling the game interface
  • JavaScript for game logic and interactivity