Ayccoe's Assets
  • Welcome
  • ayc-loading
    • Introduction
    • Installation
    • Editing Colors
    • Editing Images, Video, and Music
    • Editing Links (Discord & YouTube)
    • Editing Announcements
    • Discord/Steam Integration Configurations
  • AYC-MULTICHARACTER
    • Introduction
  • Features
  • Installation
  • Configurations
  • Advanced Configuration
  • Commands
  • AYC-DEATHSCREEN
    • Introduction
  • Installation
    • QBCore
    • ESX
    • Qbox
  • Configurations
Powered by GitBook
On this page
  1. Installation

QBCore

Edit client/dead.lua in qb-ambulancejob:

Comment this part:

if not isInHospitalBed then
    if deathTime > 0 then
        DrawTxt(0.93, 1.44, 1.0, 1.0, 0.6, Lang:t('info.respawn_txt', { deathtime = math.ceil(deathTime) }), 255, 255, 255, 255)
    else
        DrawTxt(0.865, 1.44, 1.0, 1.0, 0.6, Lang:t('info.respawn_revive', { holdtime = hold, cost = Config.BillCost }), 255, 255, 255, 255)
    end
end

And this part:

if LaststandTime > Config.MinimumRevive then
    DrawTxt(0.94, 1.44, 1.0, 1.0, 0.6, Lang:t('info.bleed_out', { time = math.ceil(LaststandTime) }), 255, 255, 255, 255)
else
    DrawTxt(0.845, 1.44, 1.0, 1.0, 0.6, Lang:t('info.bleed_out_help', { time = math.ceil(LaststandTime) }), 255, 255, 255, 255)
    if not emsNotified then
        DrawTxt(0.91, 1.40, 1.0, 1.0, 0.6, Lang:t('info.request_help'), 255, 255, 255, 255)
    else
        DrawTxt(0.90, 1.40, 1.0, 1.0, 0.6, Lang:t('info.help_requested'), 255, 255, 255, 255)
    end

    if IsControlJustPressed(0, 47) and not emsNotified then
        TriggerServerEvent('hospital:server:ambulanceAlert', Lang:t('info.civ_down'))
        emsNotified = true
    end
end

Edit DeathTimer() function from:

function DeathTimer()
    hold = 5
    while isDead do
        Wait(1000)
        deathTime = deathTime - 1
        if deathTime <= 0 then
            if IsControlPressed(0, 38) and hold <= 0 and not isInHospitalBed then
                TriggerEvent('hospital:client:RespawnAtHospital')
                hold = 5
            end
            if IsControlPressed(0, 38) then
                if hold - 1 >= 0 then
                    hold = hold - 1
                else
                    hold = 0
                end
            end
            if IsControlReleased(0, 38) then
                hold = 5
            end
        end
    end
end

To:

function DeathTimer()
    hold = 5
    while isDead do
        Wait(1000)
        deathTime = deathTime - 1
    end
end

Everything is now ready, Please restart your server.

PreviousInstallationNextESX

Last updated 9 days ago