框架esx 使用背包ox
领取红包用户

- 黄金
- 274.09 黄金
绷带的恢复是直接调用的ox背包,所以要改的话要去ox背包改
急救包的话,找到wasabi_ambulance:heal这个事件,在这里面改
找到这段代码去进行修改
急救包的话,找到wasabi_ambulance:heal这个事件,在这里面改
找到这段代码去进行修改
Lua:
RegisterNetEvent('wasabi_ambulance:heal', function(full, quiet)
local ped = wsb.cache.ped
local maxHealth = 200
if not full then
local health = GetEntityHealth(ped)
local newHealth = math.min(maxHealth, math.floor(health + maxHealth / 8))
SetEntityHealth(ped, newHealth + 0.0)
else
SetEntityHealth(ped, maxHealth + 0.0)
if wsb.framework == 'qb' then
TriggerServerEvent('hospital:server:resetHungerThirst')
TriggerServerEvent('hud:server:RelieveStress', 100)
end
end
if Config.MythicHospital then
TriggerEvent('mythic_hospital:client:RemoveBleed')
TriggerEvent('mythic_hospital:client:ResetLimbs')
end
if Config.EnableLiveInjury and full then ClearPatientSymptoms() end
if not quiet then
TriggerEvent('wasabi_bridge:notify', Strings.player_successful_heal, Strings.player_healed_desc, 'success')
end
if Config.EMSItems.heal.healBleed and next(PlayerInjury) then
for _, injury in pairs(PlayerInjury) do
if injury.data.bleed > 0 then
injury.data.bleed = 0
end
end
TriggerServerEvent('wasabi_ambulance:injurySync', PlayerInjury)
end
end)