mirror of
https://github.com/esx-framework/esx_core.git
synced 2026-08-30 17:58:54 +00:00
Fixed respawning with /revive (#87)
- Fix spawning at hostiptal with /revive command or revive by ems menu - Now correctly repawning to hospital after bleedoutTimer runs out
This commit is contained in:
+6
-2
@@ -209,6 +209,7 @@ function StartDeathTimer()
|
||||
text = text .. _U('respawn_bleedout_prompt')
|
||||
|
||||
if IsControlPressed(0, Keys['E']) and timeHeld > 60 then
|
||||
RemoveItemsAfterRPDeath()
|
||||
break
|
||||
end
|
||||
elseif Config.EarlyRespawnFine and canPayFine then
|
||||
@@ -216,6 +217,7 @@ function StartDeathTimer()
|
||||
|
||||
if IsControlPressed(0, Keys['E']) and timeHeld > 60 then
|
||||
TriggerServerEvent('esx_ambulancejob:payFine')
|
||||
RemoveItemsAfterRPDeath()
|
||||
break
|
||||
end
|
||||
end
|
||||
@@ -232,8 +234,10 @@ function StartDeathTimer()
|
||||
AddTextComponentString(text)
|
||||
DrawText(0.5, 0.8)
|
||||
end
|
||||
|
||||
RemoveItemsAfterRPDeath()
|
||||
|
||||
if bleedoutTimer < 1 and IsDead then
|
||||
RemoveItemsAfterRPDeath()
|
||||
end
|
||||
end)
|
||||
end
|
||||
|
||||
|
||||
Reference in New Issue
Block a user