Download the latest script on keymaster.fivem & unzip yeva_deathscreen
Drag script into your resources folder, for example on [qb] or [esx_addons] folder.
Don't forget to start the script in the config.lua if you put the script outside of that folder.
Configuration
The config.lua is available inside shared folder
Config = {}
-- Time a character is considered dead before initiating the respawn process, time in second
Config.DeathTimer = 300
-- Defines a cooldown period in minutes for the ambulance call button
Config.CallTimer = 5
-- Specifies the time threshold in seconds, beyond which the respawn acceptance button will be disabled after a character's death
Config.SpawnThreshold = 60
-- Determines whether the screen shake effect is enabled when a character dies
Config.EnableShakeEffect = false
-- Duration in milliseconds of the screen shake effect
Config.ShakeTime = 3000
-- Specifies the name of the screen shake effect to be used upon character death
Config.ShakeName = "DEATH_FAIL_IN_EFFECT_SHAKE"
-- Defines the intensity of the screen shake effect when a character dies
Config.ShakeIntensity = 1.0
-- If set to true, the respawn system will function independently and won't require other resources
Config.UseStandalone = false
-- If set to true, the character will instantly reappear at the defined respawn location
Config.DirectRespawn = true
-- Defines the respawn location coordinates for direct respawn
Config.RespawnLocation = vector3(341.0, -1397.3, 32.5)
-- Sets the heading (direction) of the character during direct respawn.
Config.RespawnHeading = 48.5
-- SHARED CLIENT FUNCTION
function SignalTrigger()
print('Add your trigger or export here')
end
function SpawnTrigger()
print('Add your trigger or export here')
end
exports("OpenDeathUI", function()
return ShowDeathUI()
end)
exports("CloseDeathUI", function()
return HideDeathUI()
end)