where of ambulance job script can i find set player to death true ?
u know , i want this :
If player was in battle and if Disconnect from server OR Close Fivem(alt+f4) then set player death = true
something like this :
RegisterNetEvent('PLAYER:ALTF4') AddEventHandler('PLAYER:ALTF4', function() if not ESX.GetPlayerData().IsDead then InJure = true ESX.SetPlayerData('IsDead', true) end TriggerServerEvent('esx_ambulancejob:setDaathStatus', deathCause) end)
that code is not working !
can anyone please help me ? tnx