1
0
mirror of https://github.com/OpenRCT2/OpenRCT2 synced 2026-01-15 11:03:00 +01:00

Fix #11128: null tile element in track_block_get_previous (#11144)

This commit is contained in:
Michał Janiszewski
2020-03-29 23:01:13 +02:00
committed by GitHub
parent 87b90f2304
commit d1faa228c5

View File

@@ -656,6 +656,9 @@ bool track_block_get_previous_from_zero(
*/
bool track_block_get_previous(int32_t x, int32_t y, TileElement* tileElement, track_begin_end* outTrackBeginEnd)
{
if (tileElement == nullptr)
return false;
auto trackElement = tileElement->AsTrack();
if (trackElement == nullptr)
return false;