aboutsummaryrefslogtreecommitdiff
path: root/src/main/main.cpp
diff options
context:
space:
mode:
authorthecharlesblake2017-10-27 23:25:50 +0100
committerthecharlesblake2017-10-27 23:36:39 +0100
commita841befd0ecdc0b469d6bc46b209f259358778ec (patch)
tree8ce11ab3208fb499befe8814536a27778c949210 /src/main/main.cpp
parentBH Solver with path outputted, based on user input (diff)
downloadmetasol-a841befd0ecdc0b469d6bc46b209f259358778ec.tar.gz
metasol-a841befd0ecdc0b469d6bc46b209f259358778ec.zip

Add random game generation to bh

Diffstat (limited to 'src/main/main.cpp')
-rw-r--r--src/main/main.cpp10
1 files changed, 10 insertions, 0 deletions
diff --git a/src/main/main.cpp b/src/main/main.cpp
index a7e5871..ae5e00b 100644
--- a/src/main/main.cpp
+++ b/src/main/main.cpp
@@ -22,6 +22,16 @@ int main(int argc, const char* argv[]) {
return 1;
}
+ int seed = clh.get_random_deal();
+ if (seed >= 0) {
+ game_state gs(seed);
+ solver sol(gs);
+
+ cout << "Attempting to solve with seed: " << seed << "...\n";
+ sol.run();
+ cout << sol;
+ }
+
for (auto input_json : clh.get_input_files()) {
try {
// Attempts to read the user's json into a document