From: Holger Schemel Date: Sat, 14 Dec 2024 18:10:30 +0000 (+0100) Subject: fixed graphics when digging crumbled sand with BD game engine X-Git-Tag: 4.4.0.0-test-6~2 X-Git-Url: https://git.artsoft.org/?a=commitdiff_plain;h=6efba23d7bb2bddf431300e3fe08d864da275f1d;p=rocksndiamonds.git fixed graphics when digging crumbled sand with BD game engine This change is needed for BD1 cave scheduling where animation cycle is not always in sync with the game engine. --- diff --git a/src/game_bd/bd_graphics.c b/src/game_bd/bd_graphics.c index c6fd7d03..122bd53c 100644 --- a/src/game_bd/bd_graphics.c +++ b/src/game_bd/bd_graphics.c @@ -620,7 +620,7 @@ static void gd_drawcave_crumbled(Bitmap *dest, GdGame *game, int x, int y, boole GdCave *cave = game->cave; int sx = x * cell_size - scroll_x; int sy = y * cell_size - scroll_y; - int frame = game->animcycle; + int frame = game->itercycle; int border_size = cell_size / 8; int draw = game->drawing_buffer[y][x]; int draw_last = game->last_drawing_buffer[y][x]; diff --git a/src/tools.c b/src/tools.c index 1684a8e0..6ec7373a 100644 --- a/src/tools.c +++ b/src/tools.c @@ -11268,7 +11268,7 @@ void InitGraphicInfo_BD(void) e == O_DIRT2_DIGGING_LEFT_CRUMBLED || e == O_DIRT2_DIGGING_RIGHT_CRUMBLED || e == O_DIRT2_DIGGING_UP_CRUMBLED || - e == O_DIRT2_DIGGING_DOWN_CRUMBLED ? j * 2 % 8: + e == O_DIRT2_DIGGING_DOWN_CRUMBLED ? j : j * 2); int frame = getAnimationFrame(g->anim_frames, g->anim_delay,