Fix invalid scenery entry (#8328)

This commit is contained in:
Michał Janiszewski 2018-12-05 23:01:13 +01:00 committed by GitHub
parent dc7d14163f
commit f5f3bfe087
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 2 additions and 1 deletions

View File

@ -554,7 +554,8 @@ static bool map_animation_invalidate_wall(int32_t x, int32_t y, int32_t baseZ)
sceneryEntry = tileElement->AsWall()->GetEntry();
if (!(sceneryEntry->wall.flags2 & WALL_SCENERY_2_ANIMATED) && sceneryEntry->wall.scrolling_mode == 255)
if (!sceneryEntry
|| (!(sceneryEntry->wall.flags2 & WALL_SCENERY_2_ANIMATED) && sceneryEntry->wall.scrolling_mode == 255))
continue;
int32_t z = tileElement->base_height * 8;