Installation
General
Basic Installation
Download the script from the FiveM Asset Manager.
Extract the
visn_are.pack.zip-archive into yourresourcesfolder.Rename
visn_are.packtovisn_are.Open the
configurationfolder inside thevisn_are-folder.Customize the
client_config.luaandserver_config.luato your needs.Start the script.

ESX Integration
esx_ambulancejob integration
If you are using esx_ambulancejob go into esx_ambulancejob/client/main.lua and replace:
AddEventHandler('esx:onPlayerSpawn', function()
isDead = false
if firstSpawn then
firstSpawn = false
if Config.SaveDeathStatus then
while not ESX.PlayerLoaded do
Wait(1000)
end
ESX.TriggerServerCallback('esx_ambulancejob:getDeathStatus', function(shouldDie)
if shouldDie then
Wait(1000)
SetEntityHealth(PlayerPedId(), 0)
end
end)
end
end
end)
function OnPlayerDeath()
isDead = true
ESX.UI.Menu.CloseAll()
TriggerServerEvent('esx_ambulancejob:setDeathStatus', true)
StartDeathTimer()
StartDistressSignal()
StartScreenEffect('DeathFailOut', 0, false)
endAddEventHandler('esx:onPlayerSpawn', function()
isDead = false
end)
function OnPlayerDeath()
ESX.UI.Menu.CloseAll()
endCommand Implementation
To integrate the revive command, please do the following:
Open the file
server/main.luainside theesx_ambulancejob-folder and search for the command "revive" and replace it with following code.
TriggerEvent('es:addGroupCommand', 'revive', 'admin', function(source, args ,user)
if args[1] ~= nil then
if GetPlayerName(tonumber(args[1])) ~= nil then
TriggerClientEvent('esx_ambulancejob:revive', tonumber(args[1]))
TriggerClientEvent('visn_are:resetHealthBuffer', tonumber(args[1]))
end
else
TriggerClientEvent('esx_ambulancejob:revive', source)
TriggerClientEvent('visn_are:resetHealthBuffer', source)
end
end, function(source, args, user)
TriggerClientEvent('chat:addMessage', source, { args = { '^1SYSTEM', 'Insufficient permissions.'}})
end, { help = _U('revive_help'), params = {{ name = 'id'}}})ESX.RegisterCommand('revive', 'admin', function(xPlayer, args, showError)
args.playerId.triggerEvent('esx_ambulancejob:revive')
args.playerId.triggerEvent('visn_are:resetHealthBuffer')
end, true, {help = _U('revive_help'), validate = true, arguments = { {name = 'playerId', help = 'The player id', type = 'player'} }})QBCore Integration
qb-ambulancejob Integration
If you are using qb-ambulancejob go into qb-ambulancejob/fxmanifest.lua and remove the following lines from client_scripts:
'client/wounding.lua'
'client/laststand.lua'
'client/dead.lua'Command Implementation
To integrate the revive command, please do the following:
Open the file
server/main.luainside theqb-ambulancejob-folder and search for the command "revive" and replace it with following code.
QBCore.Commands.Add("revive", Lang:t('info.revive_player_a'), {{name = "id", help = Lang:t('info.player_id')}}, false, function(source, args)
local src = source
if args[1] then
local Player = QBCore.Functions.GetPlayer(tonumber(args[1]))
if Player then
TriggerClientEvent('hospital:client:Revive', Player.PlayerData.source)
TriggerClientEvent('visn_are:resetHealthBuffer', Player.PlayerData.source)
else
TriggerClientEvent('QBCore:Notify', src, Lang:t('error.not_online'), "error")
end
else
TriggerClientEvent('hospital:client:Revive', src)
TriggerClientEvent('visn_are:resetHealthBuffer', src)
end
end, "admin")Standalone Integration
This script works out of the box for standalone. If you want to integrate custom framework things, have a look inside visn_are/script/helpers/s_functions.lua.
Revive Command
A revive command is included in the script. You can enable it in the Server Config. In order to customize the permissions for it have a look inside visn_are/script/helpers/s_functions.lua.
Last updated
Was this helpful?