Pig Dice is a game of luck and intrigue where players roll a die until they get a one or choose to stop and bank their total. First player to bank 100 points wins. {November 2016}
Specifications
-
Display a random number between 1 and 6.
-
Input: "Roll"
-
Output: 4
-
Add the number from each roll to a total.
-
Input: 4, 2, 5
-
Output: 11
-
If 1 is rolled, reset total to 0 and end turn.
- Input: 4, 2, 5, 1
- Output: 0
-
End turn manually and add "turn total" to bank.
- Input: 4, 2, 5, stop
- Output: 11 = 11
-
Switch to another player and keep a separate bank.
-
Input: player 1 stops at 11
-
Output: player 2 starts at 0
-
End game when one player's bank reaches 100.
-
Input: player 2 bank = 101
-
Output: Congratulations player 2!
Source code available at repository
Turn total does not display on second roll on easy computer's turn.
Contact one of the authors at: bradcopenhaver@gmail.com or jonathan.thom1990@gmail.com
- jquery
- Bootstrap
- javascript
- html/css
This project is licensed under the MIT license.
Copyright (c) 2016 {Brad Copenhaver, Jonathan Thom}