Advertisement
Guest User

Untitled

a guest
Feb 27th, 2020
133
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.71 KB | None | 0 0
  1. public class CrapsPlay {
  2. /**
  3. * The dice used in the game.
  4. */
  5. private Die die1, die2;
  6. private Scanner scan;
  7.  
  8. /**
  9. * Store whether the current game was a win or a loss.
  10. */
  11. private boolean won;
  12.  
  13. /**
  14. * Store whether the current game is finished or not.
  15. */
  16. private boolean finished = false;
  17.  
  18. /**
  19. * Store the number of rolls in the current game.
  20. */
  21. private int rolls;
  22.  
  23. /**
  24. * Store the first roll of the game.
  25. */
  26. private int firstRoll;
  27.  
  28. /**
  29. * Sum of the faces of the dice.
  30. */
  31. private int sumOfRoll;
  32.  
  33. /**
  34. * Store the total number of won games.
  35. */
  36. private int wonGames;
  37.  
  38. /**
  39. * Store the total number of games played.
  40. */
  41. private int gamesPlayed;
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement