An open API service indexing awesome lists of open source software.

https://github.com/hananemirzaee/pig-game

A fun and interactive two-player dice game built with HTML, CSS, and JavaScript.
https://github.com/hananemirzaee/pig-game

css dom-and-events-fundamentals html javascript mini-game

Last synced: 6 months ago
JSON representation

A fun and interactive two-player dice game built with HTML, CSS, and JavaScript.

Awesome Lists containing this project

README

          

# Pig Game

A simple dice game built with **HTML**, **CSS**, and **JavaScript**. The goal of the game is to accumulate points by rolling a die, but the player can lose all points if they roll a 1. The game ends when a player reaches 100 points.

## Features

- **Dice Rolling**: Players can roll the dice to accumulate points.
- **Score Tracking**: The game keeps track of the points for each player.
- **Game Logic**: The game ends when a player reaches 100 points, and the winner is declared.
- **Simple UI**: A clean and simple design built with HTML and CSS, with interactive elements powered by JavaScript.

## Technologies Used

- **HTML**
- **CSS**
- **JavaScript**

## How to Play

1. Open `index.html` in your browser or [click here](https://piggame-hanane.netlify.app/)
2. Click "Roll Dice" to roll the die and accumulate points.
3. If you roll a 1, you lose your points for that round.
4. The first player to reach 100 points wins the game.