OddEvenDiceGame is a simple, interactive Java-based dice game where players bet points on the outcome of rolling two dice. The game is designed to test the player's luck and decision-making skills in a fun and engaging way.
- The player starts with 100 cash points.
- The player places a bet from their available points before each round.
- Two six-sided dice are rolled.
- If the sum of the dice is an odd number, the player wins double their bet.
- If the sum is an even number, the player loses their bet.
- The game continues until the player decides to stop or runs out of cash points.
These instructions will get you a copy of the project up and running on your local machine for development and testing purposes.
To run this game, you will need:
- Java Development Kit (JDK) installed on your machine.
- A Java IDE (Integrated Development Environment) such as IntelliJ IDEA, Eclipse, or NetBeans, though not necessary, can make running and editing the code easier.
- Clone the repository or download the ZIP file of the project.
- If using an IDE:
- Import the project into your IDE.
- Ensure the JDK is correctly setup in your project settings.
- Locate the
DiceGame.java
file within the project directory.
- If using an IDE, run the
DiceGame.java
file directly through the IDE. - Alternatively, open a terminal or command prompt, navigate to the project directory, and run the following command:
java DiceGame.java