~mdw
/
sgt
/
puzzles
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Fix a couple of robustness issues.
[sgt/puzzles]
/
rect.c
diff --git
a/rect.c
b/rect.c
index
12d14b9
..
c1eaa2c
100644
(file)
--- a/
rect.c
+++ b/
rect.c
@@
-1054,7
+1054,7
@@
struct game_aux_info {
};
static char *new_game_desc(game_params *params, random_state *rs,
};
static char *new_game_desc(game_params *params, random_state *rs,
- game_aux_info **aux)
+ game_aux_info **aux
, int interactive
)
{
int *grid, *numbers = NULL;
struct rectlist *list;
{
int *grid, *numbers = NULL;
struct rectlist *list;
@@
-1691,7
+1691,7
@@
static char *validate_desc(game_params *params, char *desc)
return NULL;
}
return NULL;
}
-static game_state *new_game(game_params *params, char *desc)
+static game_state *new_game(
midend_data *me,
game_params *params, char *desc)
{
game_state *state = snew(game_state);
int x, y, i, area;
{
game_state *state = snew(game_state);
int x, y, i, area;
@@
-2496,13
+2496,13
@@
static void game_redraw(frontend *fe, game_drawstate *ds, game_state *oldstate,
}
static float game_anim_length(game_state *oldstate,
}
static float game_anim_length(game_state *oldstate,
- game_state *newstate, int dir)
+ game_state *newstate, int dir
, game_ui *ui
)
{
return 0.0F;
}
static float game_flash_length(game_state *oldstate,
{
return 0.0F;
}
static float game_flash_length(game_state *oldstate,
- game_state *newstate, int dir)
+ game_state *newstate, int dir
, game_ui *ui
)
{
if (!oldstate->completed && newstate->completed &&
!oldstate->cheated && !newstate->cheated)
{
if (!oldstate->completed && newstate->completed &&
!oldstate->cheated && !newstate->cheated)
@@
-2515,6
+2515,11
@@
static int game_wants_statusbar(void)
return FALSE;
}
return FALSE;
}
+static int game_timing_state(game_state *state)
+{
+ return TRUE;
+}
+
#ifdef COMBINED
#define thegame rect
#endif
#ifdef COMBINED
#define thegame rect
#endif
@@
-2548,4
+2553,5
@@
const struct game thegame = {
game_anim_length,
game_flash_length,
game_wants_statusbar,
game_anim_length,
game_flash_length,
game_wants_statusbar,
+ FALSE, game_timing_state,
};
};