It's another new year.
[sgt/puzzles] / solo.c
diff --git a/solo.c b/solo.c
index eb8ad80..bba2cbd 100644 (file)
--- a/solo.c
+++ b/solo.c
@@ -207,7 +207,7 @@ static void decode_params(game_params *ret, char const *string)
         if (*string == 'r' || *string == 'm' || *string == 'a') {
             int sn, sc, sd;
             sc = *string++;
-            if (*string == 'd') {
+            if (sc == 'm' && *string == 'd') {
                 sd = TRUE;
                 string++;
             } else {
@@ -331,8 +331,8 @@ static char *validate_params(game_params *params, int full)
        return "Both dimensions must be at least 2";
     if (params->c > ORDER_MAX || params->r > ORDER_MAX)
        return "Dimensions greater than "STR(ORDER_MAX)" are not supported";
-    if ((params->c * params->r) > 36)
-        return "Unable to support more than 36 distinct symbols in a puzzle";
+    if ((params->c * params->r) > 35)
+        return "Unable to support more than 35 distinct symbols in a puzzle";
     return NULL;
 }
 
@@ -1629,7 +1629,7 @@ static int solver(int c, int r, digit *grid, int maxdiff)
            if (solver_show_working) {
                char *sep = "";
                printf("%*srecursing on (%d,%d) [",
-                      solver_recurse_depth*4, "", x, y);
+                      solver_recurse_depth*4, "", x + 1, y + 1);
                for (i = 0; i < j; i++) {
                    printf("%s%d", sep, list[i]);
                    sep = " or ";
@@ -1651,7 +1651,7 @@ static int solver(int c, int r, digit *grid, int maxdiff)
 #ifdef STANDALONE_SOLVER
                if (solver_show_working)
                    printf("%*sguessing %d at (%d,%d)\n",
-                          solver_recurse_depth*4, "", list[i], x, y);
+                          solver_recurse_depth*4, "", list[i], x + 1, y + 1);
                solver_recurse_depth++;
 #endif
 
@@ -1661,7 +1661,7 @@ static int solver(int c, int r, digit *grid, int maxdiff)
                solver_recurse_depth--;
                if (solver_show_working) {
                    printf("%*sretracting %d at (%d,%d)\n",
-                          solver_recurse_depth*4, "", list[i], x, y);
+                          solver_recurse_depth*4, "", list[i], x + 1, y + 1);
                }
 #endif
 
@@ -2712,7 +2712,7 @@ static void game_set_size(drawing *dr, game_drawstate *ds,
     ds->tilesize = tilesize;
 }
 
-static float *game_colours(frontend *fe, game_state *state, int *ncolours)
+static float *game_colours(frontend *fe, int *ncolours)
 {
     float *ret = snewn(3 * NCOLOURS, float);
 
@@ -2980,11 +2980,6 @@ static float game_flash_length(game_state *oldstate, game_state *newstate,
     return 0.0F;
 }
 
-static int game_wants_statusbar(void)
-{
-    return FALSE;
-}
-
 static int game_timing_state(game_state *state, game_ui *ui)
 {
     return TRUE;
@@ -3057,7 +3052,7 @@ static void game_print(drawing *dr, game_state *state, int tilesize)
 #endif
 
 const struct game thegame = {
-    "Solo", "games.solo",
+    "Solo", "games.solo", "solo",
     default_params,
     game_fetch_preset,
     decode_params,
@@ -3088,9 +3083,9 @@ const struct game thegame = {
     game_anim_length,
     game_flash_length,
     TRUE, FALSE, game_print_size, game_print,
-    game_wants_statusbar,
+    FALSE,                            /* wants_statusbar */
     FALSE, game_timing_state,
-    0,                                /* flags */
+    REQUIRE_RBUTTON | REQUIRE_NUMPAD,  /* flags */
 };
 
 #ifdef STANDALONE_SOLVER