X-Git-Url: https://git.artsoft.org/?a=blobdiff_plain;f=src%2Fgame_sp%2FDDSpriteBuffer.c;h=e4be416487fe8259ee05cf3dce921be901028c6b;hb=6cf34a189f4a3707c9131652621dd67731f14f6b;hp=e2f47eee2195a554e31a49720aea0642bf89e06f;hpb=3ff2e8a0b5c27b99a9920bdf5ed82bc41bf40181;p=rocksndiamonds.git diff --git a/src/game_sp/DDSpriteBuffer.c b/src/game_sp/DDSpriteBuffer.c index e2f47eee..e4be4164 100644 --- a/src/game_sp/DDSpriteBuffer.c +++ b/src/game_sp/DDSpriteBuffer.c @@ -15,10 +15,6 @@ static void Blt(int pX, int pY, Bitmap *bitmap, int SpriteX, int SpriteY) int sy2 = scy + (SCR_FIELDY + 1) * TILEY; int sx = pX - sx1; int sy = pY - sy1; - int tile_x = sx / TILESIZE; - int tile_y = sy / TILESIZE; - int move_x = (sx + TILESIZE - 1) / TILESIZE; - int move_y = (sy + TILESIZE - 1) / TILESIZE; if (NoDisplayFlag) return; @@ -32,20 +28,6 @@ static void Blt(int pX, int pY, Bitmap *bitmap, int SpriteX, int SpriteY) BlitBitmap(bitmap, bitmap_db_field_sp, SpriteX, SpriteY, TILEX_VAR, TILEY_VAR, sx, sy); - - redraw[tile_x][tile_y] = TRUE; - redraw_tiles++; - - if (move_x != tile_x) - { - redraw[move_x][tile_y] = TRUE; - redraw_tiles++; - } - else if (move_y != tile_y) - { - redraw[tile_x][move_y] = TRUE; - redraw_tiles++; - } } void DDSpriteBuffer_BltImg(int pX, int pY, int graphic, int sync_frame) @@ -55,6 +37,9 @@ void DDSpriteBuffer_BltImg(int pX, int pY, int graphic, int sync_frame) if (NoDisplayFlag) return; + if (graphic < 0) + return; + getGraphicSource_SP(&g, graphic, sync_frame, -1, -1); Blt(pX, pY, g.bitmap, g.src_x, g.src_y);