mirror of
https://github.com/jimathy/jim-payments.git
synced 2026-08-19 07:16:03 +01:00
duty hotfix
fixed onDuty not being picked up on script restarts
This commit is contained in:
@@ -23,7 +23,7 @@ AddEventHandler('QBCore:Client:SetDuty', function(duty)
|
|||||||
end)
|
end)
|
||||||
|
|
||||||
--Keeps track of duty on script restarts
|
--Keeps track of duty on script restarts
|
||||||
AddEventHandler('onResourceStart', function(resource) if GetCurrentResourceName() == resource then QBCore.Functions.GetPlayerData(function(PlayerData) PlayerJob = PlayerData.job end) end end)
|
AddEventHandler('onResourceStart', function(resource) if GetCurrentResourceName() == resource then QBCore.Functions.GetPlayerData(function(PlayerData) PlayerJob = PlayerData.job onDuty = PlayerJob.onduty end) end end)
|
||||||
|
|
||||||
Citizen.CreateThread(function()
|
Citizen.CreateThread(function()
|
||||||
local jobroles = {}
|
local jobroles = {}
|
||||||
|
|||||||
Reference in New Issue
Block a user