mirror of
https://github.com/OpenRCT2/OpenRCT2.git
synced 2025-01-22 10:21:57 -05:00
Fix #9953: Crash when hacked rides attempt to find the closest mechanic
This commit is contained in:
parent
5b41afa02b
commit
e4a2b1f9c5
2 changed files with 3 additions and 0 deletions
|
@ -21,6 +21,7 @@
|
|||
- Fix: [#9729] Peeps do not take into account height difference when deciding to pathfind to a ride entrance (original bug).
|
||||
- Fix: [#9902] Doors/Portcullis do not check to make sure doors are open causing double opens.
|
||||
- Fix: [#9926] Africa - Oasis park has wrong peep spawn (original bug).
|
||||
- Fix: [#9953] Crash when hacked rides attempt to find the closest mechanic.
|
||||
- Fix: [#9955] Resizing map in while pause mode does not work and may result in freezes.
|
||||
- Fix: [#9957] When using 'no money' cheat, guests complain of running out of cash.
|
||||
- Fix: [#9970] Wait for quarter load fails.
|
||||
|
|
|
@ -356,6 +356,8 @@ TileElement* ride_get_station_exit_element(int32_t x, int32_t y, int32_t z)
|
|||
TileElement* tileElement = map_get_first_element_at(x, y);
|
||||
do
|
||||
{
|
||||
if (tileElement == nullptr)
|
||||
break;
|
||||
if (tileElement->GetType() == TILE_ELEMENT_TYPE_ENTRANCE && z == tileElement->base_height)
|
||||
return tileElement;
|
||||
} while (!(tileElement++)->IsLastForTile());
|
||||
|
|
Loading…
Reference in a new issue