diff options
author | Star Rauchenberger <fefferburbia@gmail.com> | 2023-02-17 11:13:56 -0500 |
---|---|---|
committer | Star Rauchenberger <fefferburbia@gmail.com> | 2023-02-17 11:13:56 -0500 |
commit | 6ce1edf606a384f0722f15ab25caad899c271280 (patch) | |
tree | 70782f24c761179691ea9585987c1e98a3d105cd /generator.h | |
parent | 26aa11444ca03571a2bf1ea14d54402094b5c15f (diff) | |
download | lingo-randomizer-6ce1edf606a384f0722f15ab25caad899c271280.tar.gz lingo-randomizer-6ce1edf606a384f0722f15ab25caad899c271280.tar.bz2 lingo-randomizer-6ce1edf606a384f0722f15ab25caad899c271280.zip |
allow_top_expansion
When this flag is unset (which is in most cases), top clues must be distinct from middle clues. also we forgot to have the common word filter lol
Diffstat (limited to 'generator.h')
-rw-r--r-- | generator.h | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/generator.h b/generator.h index 1c7934e..7803004 100644 --- a/generator.h +++ b/generator.h | |||
@@ -56,6 +56,7 @@ struct GenerateOptions { | |||
56 | std::string copy_hidden; // supported by single mid white | 56 | std::string copy_hidden; // supported by single mid white |
57 | bool force_two_words = false; | 57 | bool force_two_words = false; |
58 | bool must_be_broad = false; // the solution must also be gettable by bottom white/red/blue. supported by single and double | 58 | bool must_be_broad = false; // the solution must also be gettable by bottom white/red/blue. supported by single and double |
59 | bool allow_top_expansion = false; // this disables the triviality check that top puzzles can't also apply to middle | ||
59 | }; | 60 | }; |
60 | 61 | ||
61 | class Wanderlust { | 62 | class Wanderlust { |
@@ -197,7 +198,7 @@ public: | |||
197 | 198 | ||
198 | private: | 199 | private: |
199 | 200 | ||
200 | verbly::filter MakeHintFilter(verbly::filter subfilter, Height height, Colour colour, FilterDirection filter_direction); | 201 | verbly::filter MakeHintFilter(verbly::filter subfilter, Height height, Colour colour, FilterDirection filter_direction) const; |
201 | 202 | ||
202 | bool GenerateSinglePanelImpl(std::string name, Height height, Colour colour, GenerateOptions options); | 203 | bool GenerateSinglePanelImpl(std::string name, Height height, Colour colour, GenerateOptions options); |
203 | 204 | ||
@@ -215,7 +216,7 @@ private: | |||
215 | 216 | ||
216 | verbly::filter GetWordFilter(FilterDirection direction, GenerateOptions options) const; | 217 | verbly::filter GetWordFilter(FilterDirection direction, GenerateOptions options) const; |
217 | 218 | ||
218 | bool IsClueTrivial(Height height, Colour colour, const verbly::form& clue, const verbly::form& solution) const; | 219 | bool IsClueTrivial(Height height, Colour colour, const verbly::form& clue, const verbly::form& solution, GenerateOptions options = {}) const; |
219 | 220 | ||
220 | unsigned int seed_; | 221 | unsigned int seed_; |
221 | std::mt19937 rng_; | 222 | std::mt19937 rng_; |