X-Git-Url: https://git.distorted.org.uk/~mdw/sgt/puzzles/blobdiff_plain/3199a01b45fe16e540800fb73f69b4188d6e70ff..8266f3fccfd8621ac980d6209cbeac94e0a9c69b:/midend.c diff --git a/midend.c b/midend.c index 979a3b6..0d19beb 100644 --- a/midend.c +++ b/midend.c @@ -767,20 +767,9 @@ void midend_timer(midend *me, float tplus) float *midend_colours(midend *me, int *ncolours) { - game_state *state = NULL; float *ret; - if (me->nstates == 0) { - char *aux = NULL; - char *desc = me->ourgame->new_desc(me->params, me->random, - &aux, TRUE); - state = me->ourgame->new_game(me, me->params, desc); - sfree(desc); - sfree(aux); - } else - state = me->states[0].state; - - ret = me->ourgame->colours(me->frontend, state, ncolours); + ret = me->ourgame->colours(me->frontend, ncolours); { int i; @@ -810,9 +799,6 @@ float *midend_colours(midend *me, int *ncolours) } } - if (me->nstates == 0) - me->ourgame->free_game(state); - return ret; }