/pigdicereal

the real pigdice

Primary LanguageJavaScript

  • 1.Behavior: Program will generate a number value between one and six input: on click output: 1, 2, ... 6

    1. Behavior: Program will take in number and total them input: 1, 2 output: score = 3
    1. Behavior: program will collect and log total of generated numbers upon "hold" input: 2, 3, "hold" output: score = 5
    1. Behavior: program will recognize number value of 1 and subtract sum of current total. input: 1 output: score = 0
    1. Behavior: program will end player's turn upon a roll of 1, or "hold" input: 1, "hold" output: end player turn
    1. Behavior: program will differentiate between "current score" and "logged score" input: output:
    1. Upon player logged score = 100, game will end and player wins input: logged score = 100 output: you win!
  • Behavior: Program will differentiate between players. input: player 1, "hold" "roll of 1" output: switch to player two