fixedmetadata logic for seeds from dealers

does anyone read these? peepee poopoo i forgot things i patched them
This commit is contained in:
Mustache Dom authored and GitHub committed 2024-02-04 23:57:33 -08:00
1 parent cea5054554
commit 0e04e0b156
1 file changed
+4 -1
+4 -1
View File
@@ -39,6 +39,7 @@ CreateThread(function()
local dealermenu = {}
if Config.StupidassNewQbItemName then
for k, v in pairs (QBConfig.ProductsStupidNameRewrite) do
if QBCore.Functions.GetPlayerData().metadata["dealerrep"] >= v.minrep then
dealermenu[#dealermenu + 1] = {
icon = "nui://"..Config.imagelink..QBCore.Shared.Items[v.name].image,
title = v.label,
@@ -53,8 +54,10 @@ CreateThread(function()
lib.registerContext({id = 'dealermenu',title = "Dealer Menu", options = dealermenu})
end
end
else
for k, v in pairs (QBConfig.Products) do
if QBCore.Functions.GetPlayerData().metadata["dealerrep"] >= v.minrep then
dealermenu[#dealermenu + 1] = {
icon = "nui://"..Config.imagelink..QBCore.Shared.Items[v.name].image,
title = v.label,
@@ -70,8 +73,8 @@ CreateThread(function()
lib.registerContext({id = 'dealermenu',title = "Dealer Menu", options = dealermenu})
end
end
end
end)
local function RandomDeliveryItemOnRep()
local myRep = QBCore.Functions.GetPlayerData().metadata["dealerrep"]
local availableItems = {}