Fix an issue where spawn max could crash the game for some vehicles (#341)

This commit is contained in:
aa15032261
2022-07-17 04:36:05 +08:00
committed by GitHub
parent 95e00b0bae
commit d7d398906d
8 changed files with 369 additions and 244 deletions

View File

@ -104,11 +104,6 @@ namespace big
const Vehicle veh = vehicle::spawn(item.hash, spawn_location, spawn_heading);
if (g->spawn.spawn_inside)
{
vehicle::telport_into_veh(veh);
}
if (g->spawn.spawn_maxed)
{
vehicle::max_vehicle(veh);
@ -116,6 +111,11 @@ namespace big
vehicle::set_plate(veh, plate);
if (g->spawn.spawn_inside)
{
vehicle::teleport_into_vehicle(veh);
}
g_vehicle_preview_service->stop_preview();
});
ImGui::PopID();