From 9132c9ad8dd79ed13f38c14bc608a84936735b81 Mon Sep 17 00:00:00 2001 From: Michael Steenbeek Date: Sat, 20 Mar 2021 17:09:19 +0100 Subject: [PATCH] Fix #14153: NPE in Guest::UpdateRideLeaveVehicle() --- src/openrct2/peep/Guest.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/openrct2/peep/Guest.cpp b/src/openrct2/peep/Guest.cpp index 04023261f4..716d381e53 100644 --- a/src/openrct2/peep/Guest.cpp +++ b/src/openrct2/peep/Guest.cpp @@ -4018,6 +4018,8 @@ void Guest::UpdateRideLeaveVehicle() rideEntry = vehicle->GetRideEntry(); rct_ride_entry_vehicle* vehicleEntry = &rideEntry->vehicles[vehicle->vehicle_type]; + if (vehicleEntry == nullptr) + return; Var37 = ((exitLocation.direction | peep_get_waypointed_seat_location(this, ride, vehicleEntry, station_direction) * 4) * 4) | 1;