Check logic

This commit is contained in:
Mustache Dom authored and GitHub committed 2024-05-03 11:30:37 -07:00
1 parent 5de4d32401
commit 3abc9c5a6a
1 file changed
+6 -6
+6 -6
View File
@@ -212,7 +212,7 @@ options = {
icon = "fas fa-sign-in-alt", icon = "fas fa-sign-in-alt",
label = "Make Butter", label = "Make Butter",
action = function() action = function()
if not ItemCheck('mdbutter') and ItemCheck('grindedweed') then return end if not ItemCheck('mdbutter') and not ItemCheck('grindedweed') then return end
if not minigame(2, 8) then return end if not minigame(2, 8) then return end
if not progressbar(Lang.Weed.canna, 4000, 'uncuff') then return end if not progressbar(Lang.Weed.canna, 4000, 'uncuff') then return end
TriggerServerEvent("md-drugs:server:makebutter") TriggerServerEvent("md-drugs:server:makebutter")
@@ -230,7 +230,7 @@ options = {
label = "Make Brownies", label = "Make Brownies",
item = "cannabutter", item = "cannabutter",
action = function() action = function()
if not ItemCheck('cannabutter') and ItemCheck('flour') and ItemCheck('chocolate') then return end if not ItemCheck('cannabutter') and not ItemCheck('flour') and not ItemCheck('chocolate') then return end
if not minigame(2, 8) then return end if not minigame(2, 8) then return end
if not progressbar(Lang.Weed.brown, 4000, 'uncuff') then return end if not progressbar(Lang.Weed.brown, 4000, 'uncuff') then return end
TriggerServerEvent("md-drugs:server:makebrownies") TriggerServerEvent("md-drugs:server:makebrownies")
@@ -249,7 +249,7 @@ options = {
label = "Make Cookies", label = "Make Cookies",
item = "cannabutter", item = "cannabutter",
action = function() action = function()
if not ItemCheck('cannabutter') and ItemCheck('flour') then return end if not ItemCheck('cannabutter') and not ItemCheck('flour') then return end
if not minigame(2, 8) then return end if not minigame(2, 8) then return end
if not progressbar(Lang.Weed.cook, 4000, 'uncuff') then return end if not progressbar(Lang.Weed.cook, 4000, 'uncuff') then return end
TriggerServerEvent("md-drugs:server:makecookies") TriggerServerEvent("md-drugs:server:makecookies")
@@ -267,7 +267,7 @@ options = {
label = "Make Chocolate", label = "Make Chocolate",
item = "cannabutter", item = "cannabutter",
action = function() action = function()
if not ItemCheck('cannabutter') and ItemCheck('chocolate') then return end if not ItemCheck('cannabutter') and not ItemCheck('chocolate') then return end
if not minigame(2, 8) then return end if not minigame(2, 8) then return end
if not progressbar(Lang.Weed.choc, 4000, 'uncuff') then return end if not progressbar(Lang.Weed.choc, 4000, 'uncuff') then return end
TriggerServerEvent("md-drugs:server:makechocolate") TriggerServerEvent("md-drugs:server:makechocolate")
@@ -285,7 +285,7 @@ options = {
label = "Make Muffin", label = "Make Muffin",
item = "cannabutter", item = "cannabutter",
action = function() action = function()
if not ItemCheck('cannabutter') and ItemCheck('flour') then return end if not ItemCheck('cannabutter') and not ItemCheck('flour') then return end
if not minigame(2, 8) then return end if not minigame(2, 8) then return end
if not progressbar(Lang.Weed.muff, 4000, 'uncuff') then return end if not progressbar(Lang.Weed.muff, 4000, 'uncuff') then return end
TriggerServerEvent("md-drugs:server:makemuffin") TriggerServerEvent("md-drugs:server:makemuffin")
@@ -306,7 +306,7 @@ options = {
icon = "fas fa-sign-in-alt", icon = "fas fa-sign-in-alt",
label = "Make Oil", label = "Make Oil",
action = function() action = function()
if not ItemCheck('butane') and ItemCheck('grindedweed') then return end if not ItemCheck('butane') and not ItemCheck('grindedweed') then return end
if not minigame(2, 8) then if not minigame(2, 8) then
local explosion = math.random(1,100) local explosion = math.random(1,100)
local loc = GetEntityCoords(PlayerPedId()) local loc = GetEntityCoords(PlayerPedId())