From 31a870f99aca2cb38ae61e7ceb57340fb63b21c9 Mon Sep 17 00:00:00 2001 From: Bear <44989435+Developer-Bear@users.noreply.github.com> Date: Thu, 26 Aug 2021 18:29:07 -0500 Subject: [PATCH] clean up /job .. --- server/commands.lua | 10 ++-------- 1 file changed, 2 insertions(+), 8 deletions(-) diff --git a/server/commands.lua b/server/commands.lua index 1341384..a308655 100644 --- a/server/commands.lua +++ b/server/commands.lua @@ -109,14 +109,8 @@ QBCore.Commands.Add("setjob", "Set A Players Job (Admin Only)", {{name="id", hel end, "admin") QBCore.Commands.Add("job", "Check Your Job", {}, false, function(source, args) - local Player = QBCore.Functions.GetPlayer(source) - local duty = "" - if Player.PlayerData.job.onduty then - duty = "On Duty" - else - duty = "Off Duty" - end - TriggerClientEvent('QBCore:Notify', source, "[Job]: "..Player.PlayerData.job.label.. " [Grade]: "..Player.PlayerData.job.grade.name.. " [Duty]: "..duty) + local PlayerJob = QBCore.Functions.GetPlayer(source).PlayerData.job + TriggerClientEvent('QBCore:Notify', source, string.format("[Job]: %s [Grade]: %s [On Duty]: %s", PlayerJob.label, PlayerJob.grade.name, PlayerJob.onduty)) end) QBCore.Commands.Add("setgang", "Set A Players Gang (Admin Only)", {{name="id", help="Player ID"}, {name="gang", help="Name of a gang"}, {name="grade", help="Grade"}}, true, function(source, args)