diff --git a/ReallifeGamemode.Server/Managers/JobManager.cs b/ReallifeGamemode.Server/Managers/JobManager.cs index 63abaff8..af5de97d 100644 --- a/ReallifeGamemode.Server/Managers/JobManager.cs +++ b/ReallifeGamemode.Server/Managers/JobManager.cs @@ -202,13 +202,22 @@ namespace ReallifeGamemode.Server.Managers { JobBase job = GetJob(player.GetUser().JobId ?? -1); - if (job != null && job.GetUsersInJob().Contains(player) && job.CheckVehicle(player, veh) && seat == 0) + if (job != null && job.GetUsersInJob().Contains(player) && seat == 0) { - if (!playerTimersJobVehicleRespawn.ContainsKey(player)) - return; + if(job.CheckVehicle(player, veh)) + { + if (!playerTimersJobVehicleRespawn.ContainsKey(player)) + return; - playerTimersJobVehicleRespawn[player].Stop(); - playerTimersJobVehicleRespawn.Remove(player); + playerTimersJobVehicleRespawn[player].Stop(); + playerTimersJobVehicleRespawn.Remove(player); + } + else + { + player.StopAnimation(); + player.WarpOutOfVehicle(); + player.Position = player.Position.Add(new Vector3(0, 0, 2.0f)); + } } }