X-Git-Url: https://git.artsoft.org/?a=blobdiff_plain;f=src%2Fgame_em%2Fgraphics.c;h=124be8fdd1378168c80b93b9f3c77a79477fa88c;hb=54d813e45f3e66dc0ecd1fae0da578503e5c9277;hp=f33d4db800e610b6f53ead1bb26fd9aee8d6f261;hpb=6d06ba238902736bb99714dc8122bb32a286577a;p=rocksndiamonds.git diff --git a/src/game_em/graphics.c b/src/game_em/graphics.c index f33d4db8..124be8fd 100644 --- a/src/game_em/graphics.c +++ b/src/game_em/graphics.c @@ -150,8 +150,8 @@ static struct GraphicInfo_EM *getObjectGraphic(int x, int y) struct GraphicInfo_EM *g = &graphic_info_em_object[tile][frame]; if (!game.use_native_emc_graphics_engine) - getGraphicSourceObjectExt_EM(tile, frame, &g->bitmap, &g->src_x, &g->src_y, - x - 2, y - 2); + getGraphicSourceObjectExt_EM(g, tile, 7 - frame, x - 2, y - 2); + return g; } @@ -160,8 +160,8 @@ static struct GraphicInfo_EM *getPlayerGraphic(int player_nr, int anim) struct GraphicInfo_EM *g = &graphic_info_em_player[player_nr][anim][frame]; if (!game.use_native_emc_graphics_engine) - getGraphicSourcePlayerExt_EM(player_nr, anim, frame, - &g->bitmap, &g->src_x, &g->src_y); + getGraphicSourcePlayerExt_EM(g, player_nr, anim, 7 - frame); + return g; } @@ -220,6 +220,13 @@ static void DrawLevelFieldCrumbled_EM(int x, int y, int sx, int sy, if (crm == 0) /* no crumbled edges for this tile */ return; +#if 0 + if (x == 3 && y == 3 && frame == 0) + printf("::: %d, %d\n", + graphic_info_em_object[207][0].crumbled_src_x, + graphic_info_em_object[207][0].crumbled_src_y); +#endif + for (i = 0; i < 4; i++) { if (crm & (1 << i)) @@ -347,7 +354,7 @@ static void animscreen(void) if (!game.use_native_emc_graphics_engine) for (y = 2; y < EM_MAX_CAVE_HEIGHT - 2; y++) for (x = 2; x < EM_MAX_CAVE_WIDTH - 2; x++) - SetGfxAnimation_EM(Draw[y][x], frame, x - 2, y - 2); + SetGfxAnimation_EM(Draw[y][x], 7 - frame, x - 2, y - 2); for (y = top; y < top + MAX_BUF_YSIZE; y++) {