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

https://github.com/premshinde-2013/rock-paper-sissor

Want to see website click here 👇
https://github.com/premshinde-2013/rock-paper-sissor

css html javascript

Last synced: 9 months ago
JSON representation

Want to see website click here 👇

Awesome Lists containing this project

README

          

# Rock Paper Scissors Game

This is a simple implementation of the classic Rock Paper Scissors game using HTML, CSS, and JavaScript.

## How to Play

1. Clone or download this repository to your local machine.
2. Open the `index.html` file in your web browser.
3. You will see three buttons representing Rock, Paper, and Scissors.
4. Click on one of the buttons to make your choice.
5. The computer will randomly select one of the options as well.
6. The result of the game will be displayed on the screen, showing whether you won, lost, or tied with the computer.

## Technologies Used

- HTML: The structure of the game.
- CSS: Styling and layout of the game interface.
- JavaScript: The logic behind the game and handling user interactions.

## File Structure

```
├── index.html // The main HTML file containing the game interface.
├── css
│ └── styles.css // CSS file for styling the game.
└── js
└── script.js // JavaScript file containing the game logic.
```

## Game Logic

The game logic is implemented in the `script.js` file. Here's a brief overview of how it works:

1. When the user clicks on one of the buttons (Rock, Paper, or Scissors), an event listener is triggered.
2. The user's choice is recorded, and a random choice is generated for the computer (Rock, Paper, or Scissors).
3. The user's choice and the computer's choice are compared to determine the winner.
4. The result of the game is displayed on the screen.

## Customization

Feel free to customize the game by modifying the CSS styles or adding more features to the JavaScript logic. You can change the design, add animations, or even implement a score system to make the game more interactive.