From fe0f2e5a2220223f4fd617340b98729fd3888075 Mon Sep 17 00:00:00 2001 From: Star Rauchenberger Date: Tue, 14 Jan 2025 21:19:44 -0500 Subject: Added some puzzles from Variety randomizer --- ext/wittle_generator/PuzzlesetEasy.cpp | 13 ++++ ext/wittle_generator/PuzzlesetHard.cpp | 95 ++++++++++++++++++++++++++ ext/wittle_generator/PuzzlesetMedium.cpp | 112 +++++++++++++++++++++++++++++++ 3 files changed, 220 insertions(+) diff --git a/ext/wittle_generator/PuzzlesetEasy.cpp b/ext/wittle_generator/PuzzlesetEasy.cpp index 4e2f84f..d5a6ea3 100644 --- a/ext/wittle_generator/PuzzlesetEasy.cpp +++ b/ext/wittle_generator/PuzzlesetEasy.cpp @@ -373,6 +373,19 @@ const std::vector>& GetEasyPuzzles() { {Decoration::Start, 2}, {Decoration::Exit, 1}}}); }, + [](Generate& generator) { + generator.setFlag(Generate::RegularStartEnd); + generator.setFlag(Generate::FullGaps); + generator.generate(4, 4, + {{{Decoration::Gap, 7}, {Decoration::Dot, 9}}}); + }, + [](Generate& generator) { + generator.setFlag(Generate::RegularStartEnd); + generator.generate(5, 5, + {{{Decoration::Stone | Decoration::Color::Black, 5}, + {Decoration::Stone | Decoration::Color::White, 7}, + {Decoration::Dot, 7}}}); + }, }; return generator_fns; diff --git a/ext/wittle_generator/PuzzlesetHard.cpp b/ext/wittle_generator/PuzzlesetHard.cpp index c775d64..8958456 100644 --- a/ext/wittle_generator/PuzzlesetHard.cpp +++ b/ext/wittle_generator/PuzzlesetHard.cpp @@ -927,6 +927,101 @@ const std::vector>& GetHardPuzzles() { {Decoration::Star | Decoration::Color::Orange, 4}, {Decoration::Star | Decoration::Color::Magenta, 5}}}); }, + [](Generate& generator) { + generator.setGridSize(7, 7); + generator.setSymmetry(Panel::Symmetry::Rotational); + generator.setSymbol(Decoration::Exit, 0, 0); + generator.setSymbol(Decoration::Exit, 14, 14); + generator.setSymbol(Decoration::Exit, 14, 0); + generator.setSymbol(Decoration::Exit, 0, 14); + generator.setSymbol(Decoration::Start, 2, 2); + generator.setSymbol(Decoration::Start, 12, 12); + generator.setSymbol(Decoration::Start, 4, 4); + generator.setSymbol(Decoration::Start, 10, 10); + generator.setSymbol(Decoration::Start, 6, 6); + generator.setSymbol(Decoration::Start, 8, 8); + generator.generate( + 7, 7, + {{{Decoration::Stone | Decoration::Color::Magenta, 7}, + {Decoration::Stone | Decoration::Color::Black, 7}, + {Decoration::Dot, 6}}}); + }, + [](Generate& generator) { + generator.setSymbol(Decoration::Start, 0, 0); + generator.setSymbol(Decoration::Start, 5 * 2, 5 * 2); + generator.setSymbol(Decoration::Exit, 2 * 2, 0); + generator.setSymbol(Decoration::Exit, 2 * 2, 5 * 2); + generator.generate( + 5, 5, + {{{Decoration::Eraser | Decoration::Color::White, 1}, + {Decoration::Star | Decoration::Color::White, 5}, + {Decoration::Star | Decoration::Color::Black, 6}, + {Decoration::Star | Decoration::Color::Orange, 6}}}); + }, + [](Generate& generator) { + generator.setFlag(Generate::DisconnectShapes); + generator.setFlag(Generate::RegularStartEnd); + generator.generate(5, 5, + {{{Decoration::Poly | Decoration::Can_Rotate | + Decoration::Color::Yellow, + 3}, + {Decoration::Dot, 7}}}); + }, + [](Generate& generator) { + generator.setFlag(Generate::RegularStartEnd); + generator.generate( + 5, 5, + {{{Decoration::Eraser | Decoration::Color::Magenta, 1}, + {Decoration::Eraser | Decoration::Color::Green, 1}, + {Decoration::Dot, 3}, + {Decoration::Stone | Decoration::Color::Magenta, 1}, + {Decoration::Stone | Decoration::Color::Green, 1}, + {Decoration::Star | Decoration::Color::Magenta, 1}, + {Decoration::Star | Decoration::Color::Green, 1}, + {Decoration::Poly | Decoration::Color::Green, 2}, + {Decoration::Poly | Decoration::Negative | + Decoration::Color::Magenta, + 2}}}); + }, + [](Generate& generator) { + generator.setFlag(Generate::RegularStartEnd); + generator.generate( + 5, 5, + {{{Decoration::Triangle | Decoration::Color::Green, 3}, + {Decoration::Star | Decoration::Color::Green, 5}, + {Decoration::Poly | Decoration::Color::Green, 3}}}); + }, + [](Generate& generator) { + generator.setFlag(Generate::RegularStartEnd); + generator.generate( + 4, 4, + {{{Decoration::Triangle2 | Decoration::Color::Orange, 7}, + {Decoration::Dot, 9}}}); + }, + [](Generate& generator) { + generator.generate( + 6, 6, + {{{Decoration::Triangle | Decoration::Color::Orange, 11}, + {Decoration::Dot, 11}, + {Decoration::Start, 3}, + {Decoration::Exit, 1}}}); + }, + [](Generate& generator) { + generator.setSymbol(Decoration::Start, 2 * 2, 5 * 2); + generator.setSymbol(Decoration::Exit, 2 * 2, 0); + generator.generate( + 5, 5, + {{{Decoration::Stone | Decoration::Color::Black, 6}, + {Decoration::Star | Decoration::Color::Black, 6}, + {Decoration::Poly | Decoration::Color::Black, 3}}}); + }, + [](Generate& generator) { + generator.setSymbol(Decoration::Start, 5, 0); + generator.setSymbol(Decoration::Exit, 5, 12); + generator.generate(5, 6, + {{{Decoration::Poly | Decoration::Color::Yellow, 4}, + {Decoration::Dot, 5}}}); + }, }; return generator_fns; diff --git a/ext/wittle_generator/PuzzlesetMedium.cpp b/ext/wittle_generator/PuzzlesetMedium.cpp index afc7e45..8e768d1 100644 --- a/ext/wittle_generator/PuzzlesetMedium.cpp +++ b/ext/wittle_generator/PuzzlesetMedium.cpp @@ -590,6 +590,118 @@ const std::vector>& GetMediumPuzzles() { 1}, {Decoration::Poly | Decoration::Orange, 1}}}); }, + [](Generate& generator) { + generator.setFlag(Generate::FullGaps); + generator.setSymbol(Decoration::Start, 4 * 2, 4 * 2); + generator.setSymbol(Decoration::Exit, 2 * 2, 0); + generator.generate( + 5, 5, + {{{Decoration::Gap, 7}, + {Decoration::Stone | Decoration::Color::Black, 5}, + {Decoration::Stone | Decoration::Color::Magenta, 6}}}); + }, + [](Generate& generator) { + generator.setFlag(Generate::FullGaps); + generator.setFlag(Generate::RegularStartEnd); + generator.generate( + 6, 6, + {{{Decoration::Gap, 11}, + {Decoration::Star | Decoration::Color::Black, 6}, + {Decoration::Star | Decoration::Color::Magenta, 6}}}); + }, + [](Generate& generator) { + generator.generate( + 4, 4, + {{{Decoration::Start, 1}, + {Decoration::Exit, 1}, + {Decoration::Dot_Intersection, 25}, + {Decoration::Stone | Decoration::Color::Black, 3}, + {Decoration::Stone | Decoration::Color::Magenta, 3}}}); + }, + [](Generate& generator) { + generator.generate( + 4, 4, + {{{Decoration::Start, 1}, + {Decoration::Exit, 1}, + {Decoration::Dot_Intersection, 25}, + {Decoration::Star | Decoration::Color::Black, 4}, + {Decoration::Star | Decoration::Color::White, 2}}}); + }, + [](Generate& generator) { + generator.generate(4, 4, + {{{Decoration::Start, 1}, + {Decoration::Exit, 1}, + {Decoration::Dot_Intersection, 25}, + {Decoration::Poly | Decoration::Color::Black, 2}, + {Decoration::Poly | Decoration::Negative | + Decoration::Color::Magenta, + 2}}}); + }, + [](Generate& generator) { + generator.generate( + 4, 4, + {{{Decoration::Start, 1}, + {Decoration::Exit, 1}, + {Decoration::Dot_Intersection, 25}, + {Decoration::Eraser | Decoration::Color::Black, 1}, + {Decoration::Star | Decoration::Color::Black, 3}, + {Decoration::Stone | Decoration::Color::Black, 3}}}); + }, + [](Generate& generator) { + generator.setFlag(Generate::RegularStartEnd); + generator.setFlag(Generate::RequireCombineShapes); + generator.generate(4, 4, + {{{Decoration::Eraser, 1}, + {Decoration::Poly | Decoration::Color::Yellow, 3}, + {Decoration::Gap, 5}}}); + }, + [](Generate& generator) { + generator.setFlag(Generate::RegularStartEnd); + generator.generate( + 4, 4, + {{{Decoration::Dot, 9}, + {Decoration::Eraser | Decoration::Color::Green, 2}}}); + }, + [](Generate& generator) { + generator.setFlag(Generate::RegularStartEnd); + generator.generate( + 4, 4, + {{{Decoration::Dot, 11}, + {Decoration::Eraser | Decoration::Color::Green, 2}}}); + }, + [](Generate& generator) { + generator.setFlag(Generate::RegularStartEnd); + generator.generate( + 5, 5, + {{{Decoration::Dot, 15}, + {Decoration::Eraser | Decoration::Color::Green, 2}}}); + }, + [](Generate& generator) { + generator.setFlag(Generate::RegularStartEnd); + generator.generate( + 5, 5, + {{{Decoration::Dot, 17}, + {Decoration::Eraser | Decoration::Color::Green, 2}}}); + }, + [](Generate& generator) { + generator.setFlag(Generate::RegularStartEnd); + generator.generate( + 5, 5, {{{Decoration::Triangle1 | Decoration::Color::Magenta, 15}}}); + }, + [](Generate& generator) { + generator.setSymbol(Decoration::Start, 2 * 2, 5 * 2); + generator.setSymbol(Decoration::Exit, 2 * 2, 0); + generator.generate( + 5, 5, + {{{Decoration::Stone | Decoration::Color::Black, 5}, + {Decoration::Stone | Decoration::Color::White, 5}, + {Decoration::Triangle | Decoration::Color::Orange, 5}}}); + }, + [](Generate& generator) { + generator.setFlag(Generate::RegularStartEnd); + generator.generate( + 6, 6, {{{Decoration::Triangle | Decoration::Color::Orange, 15}}}); + }, }; return generator_fns; -- cgit 1.4.1