patch for pharma, new callback to do animations and progressbar checks
This commit is contained in:
1 parent
f1ed2c0860
commit
cf5cfba909
7 files changed
+63
-68
No files matched your search
@@ -640,4 +640,9 @@ CreateThread(function()
|
||||
TriggerEvent('Mescaline:init')
|
||||
TriggerEvent('shrooms:init')
|
||||
TriggerEvent('weed:init')
|
||||
end)
|
||||
|
||||
lib.callback.register('md-drugs:client:uncuff', function()
|
||||
if not progressbar('Uncuffing', 4000, 'uncuff') then return end
|
||||
return true
|
||||
end)
|
||||
@@ -1,7 +1,7 @@
|
||||
local QBCore = exports['qb-core']:GetCoreObject()
|
||||
CreateThread(function()
|
||||
local config = lib.callback.await('md-drugs:server:getLocs', false)
|
||||
local model = {"g_m_y_famdnf_01", 's_m_m_doctor_01', 'u_m_m_jesus_01'}
|
||||
local model = {"g_m_y_famdnf_01", 's_m_m_doctor_01', 'u_m_m_jesus_01', "prop_cooker_03"}
|
||||
for k, v in pairs (model) do
|
||||
lib.requestModel(v, Config.RequestModelTime)
|
||||
end
|
||||
@@ -20,4 +20,5 @@ CreateThread(function()
|
||||
AddSingleModel(SyrupLocation, { type = "client", label = Lang.targets.lean.git, icon = "fa-solid fa-circle-info", event = "md-drugs:client:getsyruplocationtobuy", distance = 2.0}, nil )
|
||||
AddSingleModel(WeedGuy, {label = "Weed Shop",icon = "fas fa-eye", action = function() makeMenu('WeedShop') lib.showContext('WeedShop')end}, nil)
|
||||
AddSingleModel(methdealer,{label = Lang.targets.meth.mission, icon = "fas fa-eye", action = function() Notify(Lang.meth.mission, "success") SpawnMethCarPedChase() end,},nil )
|
||||
|
||||
end)
|
||||
+4
-13
@@ -1,15 +1,10 @@
|
||||
local QBCore = exports['qb-core']:GetCoreObject()
|
||||
|
||||
lib.callback.register("md-drugs:client:prescriptionpad", function(data)
|
||||
lib.callback.register("md-drugs:client:prescriptionpad", function(data, op)
|
||||
if not QBCore.Functions.GetPlayerData().job.type == 'ems' then return end
|
||||
local input = lib.inputDialog('Who To Give A Prescription To?',{
|
||||
{type = 'select', label = 'Player Name', options = data},
|
||||
{type = 'select', label = 'Prescription', options = {
|
||||
{label = 'Vicodin', value = 'vicodin_prescription'},
|
||||
{label = 'Adderal', value = 'adderal_prescription'},
|
||||
{label = 'Morphine', value = 'morphine_prescription'},
|
||||
{label = 'Xanax', value = 'xanax_prescription'}
|
||||
}}})
|
||||
{type = 'select', label = 'Prescription', options = op}})
|
||||
if not progressbar(Lang.Pharma.write, 4000, 'notepad') then return end
|
||||
return {who = input[1], what = input[2]}
|
||||
end)
|
||||
@@ -19,11 +14,7 @@ RegisterNetEvent("md-drugs:client:fillprescription", function(data)
|
||||
TriggerServerEvent("md-drugs:server:fillprescription", data.data)
|
||||
end)
|
||||
|
||||
RegisterNetEvent("md-drugs:client:unbottle", function(item)
|
||||
lib.callback.register("md-drugs:client:unbottle", function()
|
||||
if not progressbar(Lang.Pharma.open, 4000, 'uncuff') then return end
|
||||
if item.name == 'vicodinbottle' then item = 'vicodin' end
|
||||
if item.name == 'adderalbottle' then item = 'adderal' end
|
||||
if item.name == 'morphinebottle' then item = 'morphine' end
|
||||
if item.name == 'xanaxbottle' then item = 'xanax' end
|
||||
TriggerServerEvent('md-drugs:server:unbottle', item)
|
||||
return true
|
||||
end)
|
||||
+8
-8
@@ -125,6 +125,12 @@ AddBoxZoneSingle('makeoil',config.singleSpot.MakeOil, {
|
||||
if hasJob() and exploded == false then return true end
|
||||
end,
|
||||
} )
|
||||
local stove = CreateObject("prop_cooker_03",config.singleSpot.MakeButter.x, config.singleSpot.MakeButter.y, config.singleSpot.MakeButter.z-1, true, false)
|
||||
SetEntityHeading(stove, 270.00)
|
||||
FreezeEntityPosition(stove, true)
|
||||
local stove2 = CreateObject("prop_cooker_03",config.singleSpot.MakeOil.x,config.singleSpot.MakeOil.y, config.singleSpot.MakeOil.z-1, true, false)
|
||||
SetEntityHeading(stove2, 90.00)
|
||||
FreezeEntityPosition(stove2, true)
|
||||
end)
|
||||
|
||||
CreateThread(function()
|
||||
@@ -137,12 +143,6 @@ CreateThread(function()
|
||||
BikerWeedFarm.Plant4.Clear(false) BikerWeedFarm.Plant5.Clear(false) BikerWeedFarm.Plant6.Clear(false)
|
||||
BikerWeedFarm.Plant7.Clear(false) BikerWeedFarm.Plant8.Clear(false) BikerWeedFarm.Plant9.Clear(false)
|
||||
RefreshInterior(BikerWeedFarm.interiorId)
|
||||
local stove = CreateObject("prop_cooker_03",vector3(1045.49, -3198.46, -38.15-1), true, false)
|
||||
SetEntityHeading(stove, 270.00)
|
||||
FreezeEntityPosition(stove, true)
|
||||
local stove2 = CreateObject("prop_cooker_03",vector3(1038.90, -3198.66, -38.17-1), true, false)
|
||||
SetEntityHeading(stove2, 90.00)
|
||||
FreezeEntityPosition(stove2, true)
|
||||
end)
|
||||
|
||||
|
||||
@@ -155,7 +155,7 @@ RegisterNetEvent("md-drugs:client:grind", function()
|
||||
end)
|
||||
|
||||
RegisterNetEvent("md-drugs:client:dodabs", function()
|
||||
if not progressbar('Doing Dabs', 4000, 'bong2') then return end
|
||||
if not progressbar('Doing Dabs', 4000, 'bong2') then AlienEffect() return end
|
||||
AlienEffect()
|
||||
end)
|
||||
|
||||
@@ -207,4 +207,4 @@ end)
|
||||
|
||||
RegisterNetEvent('md-drugs:client:rollBlunt', function(data)
|
||||
lib.showContext('mddrugsblunts')
|
||||
end)
|
||||
end)
|
||||
Reference in new issue
Block a user