summary refs log tree commit diff stats
diff options
context:
space:
mode:
authorStar Rauchenberger <fefferburbia@gmail.com>2022-12-09 14:50:53 -0500
committerStar Rauchenberger <fefferburbia@gmail.com>2022-12-09 14:50:53 -0500
commitfcb1ac0269dde77cd0a69c26b819127f861bd580 (patch)
treee03bb675e06310293b0756c5274f10e6b9702e69
parent1db4d3569dfc85918bff6ed0e16dec89e83b4872 (diff)
downloadlingo-fcb1ac0269dde77cd0a69c26b819127f861bd580.tar.gz
lingo-fcb1ac0269dde77cd0a69c26b819127f861bd580.tar.bz2
lingo-fcb1ac0269dde77cd0a69c26b819127f861bd580.zip
Top purple now matches the game's behaviour
This also fixes middle purple, which was not working before.

fixes #4
-rw-r--r--lingo.cpp16
1 files changed, 14 insertions, 2 deletions
diff --git a/lingo.cpp b/lingo.cpp index fdc4619..c6f9427 100644 --- a/lingo.cpp +++ b/lingo.cpp
@@ -144,10 +144,22 @@ verbly::filter makeHintFilter(verbly::filter subfilter, Height height, Colour co
144 case kPurple: { 144 case kPurple: {
145 switch (height) { 145 switch (height) {
146 case kMiddle: { 146 case kMiddle: {
147 return (verbly::form::merographs %= (verbly::form::length >= 4 && (verbly::form::holographs %= subfilter))); 147 return (verbly::form::holographs %=
148 verbly::filter("midpurp", false,
149 (verbly::form::length >= 4 && (verbly::form::merographs %=
150 (subfilter && verbly::filter(
151 verbly::form::id,
152 verbly::filter::comparison::field_does_not_equal,
153 verbly::form::id))))));
148 } 154 }
149 case kTop: { 155 case kTop: {
150 return (verbly::pronunciation::rhymes %= subfilter); 156 return (verbly::pronunciation::holophones %=
157 verbly::filter("toppurp", false,
158 (verbly::pronunciation::numOfSyllables >= 2 && (verbly::pronunciation::merophones %=
159 (subfilter && verbly::filter(
160 verbly::pronunciation::id,
161 verbly::filter::comparison::field_does_not_equal,
162 verbly::pronunciation::id))))));
151 } 163 }
152 default: break; // Not supported yet. 164 default: break; // Not supported yet.
153 } 165 }