Fix #5803: Null map element in onridephoto (#5852)

This commit is contained in:
Michał Janiszewski 2017-07-11 13:34:11 +02:00 committed by Ted John
parent ec236f0bf5
commit ae282f782e
1 changed files with 2 additions and 0 deletions

View File

@ -312,6 +312,8 @@ static bool map_animation_invalidate_track_onridephoto(sint32 x, sint32 y, sint3
mapElement = map_get_first_element_at(x >> 5, y >> 5);
do {
if (mapElement == NULL)
break;
if (mapElement->base_height != baseZ)
continue;
if (map_element_get_type(mapElement) != MAP_ELEMENT_TYPE_TRACK)