Infrastructure change: game_anim_length and game_flash_length now

both get passed a pointer to the game_ui. This means that if they
need to note down information for the redraw function about what
_type_ of flash or animation is required, they now have somewhere to
do so.

[originally from svn r5858]
This commit is contained in:
Simon Tatham
2005-05-30 07:55:27 +00:00
parent 8fa365a7b4
commit 0f423f0b3a
12 changed files with 28 additions and 25 deletions

View File

@ -212,7 +212,8 @@ static void midend_finish_move(midend_data *me)
flashtime = me->ourgame->flash_length(me->oldstate ? me->oldstate :
me->states[me->statepos-2].state,
me->states[me->statepos-1].state,
me->oldstate ? me->dir : +1);
me->oldstate ? me->dir : +1,
me->ui);
if (flashtime > 0) {
me->flash_pos = 0.0F;
me->flash_time = flashtime;
@ -333,7 +334,7 @@ static int midend_really_process_key(midend_data *me, int x, int y, int button)
} else {
anim_time = me->ourgame->anim_length(oldstate,
me->states[me->statepos-1].state,
me->dir);
me->dir, me->ui);
}
me->oldstate = oldstate;