game_drawstate *ds, int x, int y, int button)
{
int cx, cy;
- int n, dx, dy;
+ int dx, dy;
char buf[80];
button &= ~MOD_MASK;
if (cx == -1) dx = +1;
else if (cx == state->width) dx = -1;
else return NULL;
- n = state->width;
dy = 0;
}
else if (cx >= 0 && cx < state->width && cx != state->cx)
if (cy == -1) dy = +1;
else if (cy == state->height) dy = -1;
else return NULL;
- n = state->height;
dx = 0;
}
else
return ret;
}
-static void draw_thick_line(drawing *dr, int x1, int y1, int x2, int y2,
- int colour)
+static void draw_filled_line(drawing *dr, int x1, int y1, int x2, int y2,
+ int colour)
{
draw_line(dr, x1-1, y1, x2-1, y2, COL_WIRE);
draw_line(dr, x1+1, y1, x2+1, y2, COL_WIRE);
if (tile & dir) {
ex = (TILE_SIZE - TILE_BORDER - 1.0F) / 2.0F * X(dir);
ey = (TILE_SIZE - TILE_BORDER - 1.0F) / 2.0F * Y(dir);
- draw_thick_line(dr, bx+(int)cx, by+(int)cy,
- bx+(int)(cx+ex), by+(int)(cy+ey),
- COL_WIRE);
+ draw_filled_line(dr, bx+(int)cx, by+(int)cy,
+ bx+(int)(cx+ex), by+(int)(cy+ey),
+ COL_WIRE);
}
}
for (dir = 1; dir < 0x10; dir <<= 1) {
static void game_redraw(drawing *dr, game_drawstate *ds, game_state *oldstate,
game_state *state, int dir, game_ui *ui, float t, float ft)
{
- int x, y, tx, ty, frame;
+ int x, y, frame;
unsigned char *active;
float xshift = 0.0;
float yshift = 0.0;
t = ANIM_TIME - t;
}
- tx = ty = -1;
if (oldstate && (t < ANIM_TIME)) {
/*
* We're animating a slide, of row/column number
return 0.0F;
}
+static int game_status(game_state *state)
+{
+ return state->completed ? +1 : 0;
+}
+
static int game_timing_state(game_state *state, game_ui *ui)
{
return FALSE;
game_redraw,
game_anim_length,
game_flash_length,
+ game_status,
FALSE, FALSE, game_print_size, game_print,
TRUE, /* wants_statusbar */
FALSE, game_timing_state,