diff options
| author | Simon Tatham <anakin@pobox.com> | 2005-06-10 11:29:59 +0000 |
|---|---|---|
| committer | Simon Tatham <anakin@pobox.com> | 2005-06-10 11:29:59 +0000 |
| commit | 363dadee0c87df57ac82ac99ea452ed757391869 (patch) | |
| tree | d5084c03be7ee1caad7820f64eea053335015e8f | |
| parent | 98c90052c98b19c43a0a1e4fec8bbed10d7a6d55 (diff) | |
| download | puzzles-363dadee0c87df57ac82ac99ea452ed757391869.zip puzzles-363dadee0c87df57ac82ac99ea452ed757391869.tar.gz puzzles-363dadee0c87df57ac82ac99ea452ed757391869.tar.bz2 puzzles-363dadee0c87df57ac82ac99ea452ed757391869.tar.xz | |
Overzealous last-move tracking during shuffle was causing lockups on
2x2 grid generation.
[originally from svn r5939]
| -rw-r--r-- | netslide.c | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -582,7 +582,7 @@ static char *new_game_desc(game_params *params, random_state *rs, if (col == prevrowcol) { if (dir == 2-prevdir) continue; /* undoes last move */ - else if ((nrepeats+1)*2 > h) + else if (dir == prevdir && (nrepeats+1)*2 > h) continue; /* makes fewer moves */ } slide_col_int(w, h, tiles, 1 - dir, col); @@ -593,7 +593,7 @@ static char *new_game_desc(game_params *params, random_state *rs, if (row == prevrowcol) { if (dir == 4-prevdir) continue; /* undoes last move */ - else if ((nrepeats+1)*2 > w) + else if (dir == prevdir && (nrepeats+1)*2 > w) continue; /* makes fewer moves */ } slide_row_int(w, h, tiles, 2 - dir, row); |