diff options
author | Erich Eckner <git@eckner.net> | 2020-05-21 00:19:01 +0200 |
---|---|---|
committer | Erich Eckner <git@eckner.net> | 2020-05-21 00:19:01 +0200 |
commit | 9225de99aca3d50a5d2e7b54d70ee78fe26f239d (patch) | |
tree | 1674f876bc6dec5bb6bb981ff105d8529a3619e5 | |
parent | f6b497c56081f0c6c8810e0f03deb8c539192a42 (diff) | |
download | Raetsel-9225de99aca3d50a5d2e7b54d70ee78fe26f239d.tar.xz |
raetselunit.pas: fail early if riddle cannot be filled
-rw-r--r-- | raetselunit.pas | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/raetselunit.pas b/raetselunit.pas index 121a9ea..b78b37b 100644 --- a/raetselunit.pas +++ b/raetselunit.pas @@ -345,8 +345,9 @@ begin if assigned(onSetCaption) then onSetCaption(intToStr(zufallSE.value)); zufallSE.value:=random(zufallSE.maxValue+1); - vorbereiten; - loesen(-1); + repeat + vorbereiten; + until loesen(-1); randErzeugen; leeren; startFelderFestlegen; |