Skip to content

Instantly share code, notes, and snippets.

@grancalavera
Last active September 29, 2018 14:15
Show Gist options
  • Save grancalavera/723bd80f7010d7a2db769a8e14a0c92e to your computer and use it in GitHub Desktop.
Save grancalavera/723bd80f7010d7a2db769a8e14a0c92e to your computer and use it in GitHub Desktop.
Station Race*
Station Race*
Begin*
setup new game -> Setup
Setup
register player -> Setup
start -> Has Enough Players?
Has Enough Players?
has enough players -> Turn
does not have enough players -> Setup
Turn
go left -> Turn
go right -> Turn
go first -> Turn
go last -> Turn
get off the train -> Has Winner?
Has Winner?
has winner -> Over
does not have winner -> Turn Result
Turn Result
next turn -> Turn
Over
play again -> Turn
new game -> Begin
function render(model){
let current_state_name = model.active_states[0].name;
return $("h1",
{style: {color: "darkBlue"}},
`The current state is: ${current_state_name}`);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment