aboutsummaryrefslogtreecommitdiff
path: root/src/test/test_helper.cpp
diff options
context:
space:
mode:
authorTom Harley2019-02-17 00:16:12 +0000
committerTom Harley2019-02-17 00:16:12 +0000
commit5fb3cdc6faee083ceb43dee168b440c92ba951ad (patch)
treee80f8bad860153a4862b9578f7182f009ae648eb /src/test/test_helper.cpp
parentSolve a Klondike deal (diff)
downloadmetasol-5fb3cdc6faee083ceb43dee168b440c92ba951ad.tar.gz
metasol-5fb3cdc6faee083ceb43dee168b440c92ba951ad.zip

Split Solvitaire k+ moves into stock moves

In Solvitaire, going through the stock in stock-waste games is bundled with the move out of the waste, in what’s called a k-plus move. This makes sense in Solvitaire, but in this system having each stock move be explicit helps because it itemises all moves similarly, making shaving off single moves easy.

The calculate_stock_moves function uses a simulation rather than a simple calculation, which has a couple of downsides: 1. it’s slower than a calculation; 2. it loops infinitely when given an index that’s impossible to reach.

Diffstat (limited to 'src/test/test_helper.cpp')
0 files changed, 0 insertions, 0 deletions