senthiljruby / dicegame

Interactive dice game using javascript

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Dice Game!

This is a simple web-based dice game built using HTML, CSS, and JavaScript. The game allows two players to take turns rolling dice, and the player with the higher dice value wins the round.

πŸ“ Table of Contents

🧐 How to Play

  • Open the index.html file in a web browser.
  • Enter the number of players when prompted.
  • Enter the names of the players.
  • Click the "Roll the Dice" button to start the game.
  • The dice will roll, and the winner of the round will be displayed.
  • The win track will keep a record of each player's wins.
  • Click the "Toggle View" button to switch between the table view and chart view of the win track.
  • To reset the game, click the "Reset" button.

🎈 Features

  • Dynamic creation of player elements based on the number of players.
  • Random dice rolling and determination of the round winner.
  • Highlighting the winning player and displaying the winner's name.
  • Update and display of the win track table with each round's results.
  • Toggle between table view and chart view of the win track using the "Toggle View" button.
  • Chart visualization of the win track using bar chart and pie chart.
  • Responsive design for various screen sizes.

🏁 Technologies Used

  • HTML
  • CSS
  • JavaScript
  • Chart.js library for chart visualization

🏁 Author

This project is created by Senthil Kumar Bhaskaran.

🏁 License

This project is licensed under the MIT License.

Feel free to customize and modify the code to suit your needs. Have fun playing the dice game!

About

Interactive dice game using javascript

License:MIT License


Languages

Language:JavaScript 60.0%Language:CSS 24.9%Language:HTML 15.1%