diff --git a/ReallifeGamemode.Server/Job/BusDriverJob.cs b/ReallifeGamemode.Server/Job/BusDriverJob.cs index 9bf72a2d..d58ff39f 100644 --- a/ReallifeGamemode.Server/Job/BusDriverJob.cs +++ b/ReallifeGamemode.Server/Job/BusDriverJob.cs @@ -420,6 +420,7 @@ namespace ReallifeGamemode.Server.Job //rt.BusLetzterCheckpoint() } } + [RemoteEvent("BusLetzterCheckpoint")] public static void BusLetzterCheckpoint(Player player) { diff --git a/ReallifeGamemode.Server/Util/CheckPointHandle.cs b/ReallifeGamemode.Server/Util/CheckPointHandle.cs index 9177bd09..7569aee4 100644 --- a/ReallifeGamemode.Server/Util/CheckPointHandle.cs +++ b/ReallifeGamemode.Server/Util/CheckPointHandle.cs @@ -153,6 +153,7 @@ namespace ReallifeGamemode.Server.Util } //user.TriggerEvent("CLIENT:UnFreezeVehicle", veh); } + [RemoteEvent("playerInCheckpoint")] public void PlayerInCheckpoint(Player user) { @@ -303,12 +304,12 @@ namespace ReallifeGamemode.Server.Util CheckPointHandle.RemovePlayerHandlerFromList(this.player); DeleteCheckpoints(); player.SetData("HatRoute", false); - if (player.GetUser().JobId == 3) + if (player.GetUser().JobId == 3 && player.HasData("Route")) { //PilotJob.payWage(player, 200); PilotJob.PilotLetzterCheckpoint(player); } - if (player.GetUser().JobId == 4) + else if (player.GetUser().JobId == 4 && player.HasData("Route")) { //BusDriverJob.payWage(player, 200); //CheckPointHandle.BusCheckpoint(player);