diff --git a/missions/techdemo/followtheleader.cpn b/missions/techdemo/followtheleader.cpn new file mode 100644 index 000000000..589267b38 Binary files /dev/null and b/missions/techdemo/followtheleader.cpn differ diff --git a/src/cdogs/draw.c b/src/cdogs/draw.c index 504f212f4..0c31e5115 100644 --- a/src/cdogs/draw.c +++ b/src/cdogs/draw.c @@ -239,7 +239,7 @@ void DrawFloor(DrawBuffer *b, int xOffset) x < b->width; x++, tile++, pos.x += TILE_WIDTH) { - if (PicIsNotNone(tile->pic) && + if (tile->pic != NULL && PicIsNotNone(tile->pic) && !(tile->flags & (MAPTILE_IS_WALL | MAPTILE_OFFSET_PIC))) { BlitMasked( diff --git a/src/cdogs/draw_buffer.c b/src/cdogs/draw_buffer.c index 7ef036356..c395ceebd 100644 --- a/src/cdogs/draw_buffer.c +++ b/src/cdogs/draw_buffer.c @@ -102,6 +102,10 @@ void DrawBufferSetFromMap( { *bufTile = map[y][x]; } + else + { + *bufTile = tileNone; + } } bufTile += tilesXY.x - buffer->width; } diff --git a/src/cdogs/map.c b/src/cdogs/map.c index a15f07407..b4ce948b8 100644 --- a/src/cdogs/map.c +++ b/src/cdogs/map.c @@ -79,6 +79,7 @@ #define MAP_ACCESSBITS 0x0F00 +Tile tileNone = { NULL, { { 0, 0 }, { 0, 0 }, NULL }, 0, 0, NULL }; Tile gMap[YMAX][XMAX]; diff --git a/src/cdogs/map.h b/src/cdogs/map.h index 1dbb9c15b..0fba44705 100644 --- a/src/cdogs/map.h +++ b/src/cdogs/map.h @@ -119,6 +119,7 @@ typedef struct TTileItem *things; } Tile; +extern Tile tileNone; extern Tile gMap[YMAX][XMAX]; #define Map( x, y) gMap[y][x]