Probability calculator for the board game CamelUp.
Go to file
2021-07-19 10:45:29 -07:00
.gitignore eliminate unnecessary indirection in ColorStack iterator 2021-03-22 17:23:28 -07:00
colors.nim switch to bitshifting operations (turns out to be slower, oh well) 2021-07-19 10:45:29 -07:00
combinators.nim add (very) basic CLI 2021-07-12 15:46:06 -07:00
config.nims switch to bitshifting operations (turns out to be slower, oh well) 2021-07-19 10:45:29 -07:00
cup.nim make use of prettier dislpays 2021-07-14 22:05:03 -07:00
fixedseq.nim switch to bitshifting operations (turns out to be slower, oh well) 2021-07-19 10:45:29 -07:00
game.nim switch to bitshifting operations (turns out to be slower, oh well) 2021-07-19 10:45:29 -07:00
README.md make use of prettier dislpays 2021-07-14 22:05:03 -07:00
shiftstack.nim switch to bitshifting operations (turns out to be slower, oh well) 2021-07-19 10:45:29 -07:00
simulation.nim prettier displays for game board and win probabilities 2021-07-14 21:49:10 -07:00
test.nim switch to bitshifting operations (turns out to be slower, oh well) 2021-07-19 10:45:29 -07:00
ui.nim prettier displays for game board and win probabilities 2021-07-14 21:49:10 -07:00

cup - CamelUp probability calculator

This tool calculates probable outcomes for the board game CamelUp. It can calculate all possible outcomes for a single game leg in about 5ms, so effectively instantaneously. Full-game calculations take a little bit longer and are not exact (since it isn't practical to simulate all possible full game states.) However it can easily simulate a million random games in about 80ms in the worst case, which should provide estimates accurate to within about 0.2%. (Numbers from running on a Ryzen 3700X.)

Usage: 
  cup [-i] SPACE:STACK [...SPACE:STACK] [DICE]

SPACE refers to a numbered board space (1-16).
STACK refers to a stack of camel colors from bottom to top, e.g. 
      YBR (Yellow, Blue, Red, with Red on top).
DICE refers to the set of dice that have already been rolled,
     e.g. GPR (Green, Purple, Red)

Options:
  -i      Interactive mode (currently unimplemented)
  -h      Show this message and exit