fix for lean and meth missions
update lsd heroin tables
This commit is contained in:
1 parent
b56e585691
commit
79569a18b6
4 files changed
+42
-76
No files matched your search
+9
-11
@@ -1,14 +1,15 @@
|
||||
local PoppyPlants = {}
|
||||
local herointable = false
|
||||
local dirty = false
|
||||
|
||||
local function createLabKit(coord, head)
|
||||
local function createLabKit(coord, head)
|
||||
local heroinlabkit = CreateObject("v_ret_ml_tablea", coord.x, coord.y, coord.z - 1, true, false,false)
|
||||
SetEntityHeading(heroinlabkit, head)
|
||||
PlaceObjectOnGroundProperly(heroinlabkit)
|
||||
AddMultiModel(heroinlabkit, {
|
||||
{ event = "md-drugs:client:heatliquidheroin", icon = "fa-solid fa-temperature-high", label = Lang.targets.heroin.cook, data = heroinlabkit},
|
||||
{ event = "md-drugs:client:getheroinkitback", icon = "fas fa-box-circle-check", label = Lang.targets.heroin.up, data = heroinlabkit, canInteract = function() if herointable then return true end end}},
|
||||
heroinlabkit)
|
||||
{data = heroinlabkit, event = "md-drugs:client:heatliquidheroin", icon = "fa-solid fa-temperature-high", label = Lang.targets.heroin.cook, canInteract = function() if not dirty then return true end end},
|
||||
{data = heroinlabkit, event = "md-drugs:client:getheroinkitback", icon = "fas fa-box-circle-check", label = Lang.targets.heroin.up, canInteract = function() if not dirty then return true end end},
|
||||
{data = heroinlabkit, event = "md-drugs:client:cleanheroinlabkit",icon = "fa-solid fa-hand-sparkles",label = Lang.targets.heroin.clean,canInteract = function() if dirty then return true end end}},heroinlabkit)
|
||||
end
|
||||
|
||||
local function pickher(loc)
|
||||
@@ -88,16 +89,12 @@ RegisterNetEvent("md-drugs:client:heatliquidheroin", function(data)
|
||||
local loc, head = GetEntityCoords(data.data), GetEntityHeading(data.data)
|
||||
if not ItemCheck('emptyvial') then return end
|
||||
if not minigame() then
|
||||
dirty = true
|
||||
TriggerServerEvent("md-drugs:server:failheatingheroin")
|
||||
DeleteObject(data.data)
|
||||
local dirtylabkitheroin = CreateObject("v_ret_ml_tablea", loc.x, loc.y, loc.z-1, true, false)
|
||||
SetEntityHeading(dirtylabkitheroin, head)
|
||||
PlaceObjectOnGroundProperly(dirtylabkitheroin)
|
||||
loadParticle("core")
|
||||
local heroinkit = StartParticleFxLoopedOnEntity("exp_air_molotov", dirtylabkitheroin, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 1.5, false, false, false)
|
||||
local heroinkit = StartParticleFxLoopedOnEntity("exp_air_molotov", data.data, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 1.5, false, false, false)
|
||||
SetParticleFxLoopedAlpha(heroinkit, 3.0)
|
||||
SetPedToRagdoll(PlayerPedId(), 1300, 1300, 0, 0, 0, 0)
|
||||
AddMultiModel(dirtylabkitheroin, {{event = "md-drugs:client:cleanheroinlabkit",icon = "fa-solid fa-hand-sparkles",label = Lang.targets.heroin.clean, data = dirtylabkitheroin}}, nil )
|
||||
return end
|
||||
if not progressbar(Lang.Heroin.success, 4000, 'uncuff') then return end
|
||||
TriggerServerEvent("md-drugs:server:heatliquidheroin")
|
||||
@@ -106,7 +103,8 @@ end)
|
||||
RegisterNetEvent("md-drugs:client:cleanheroinlabkit", function(data)
|
||||
if not ItemCheck('cleaningkit') then return end
|
||||
if not progressbar(Lang.Heroin.clean, 4000, 'clean') then return end
|
||||
TriggerServerEvent("md-drugs:server:removecleaningkitheroin", data.data)
|
||||
local done = lib.callback.await('removeCleaningkit', false)
|
||||
if done then dirty = false end
|
||||
end)
|
||||
|
||||
RegisterNetEvent("md-drugs:client:deletedirtyheroin", function(data)
|
||||
|
||||
Reference in new issue
Block a user