βοΈConfiguration
Detailed explanation of the config file to adapt the resource to your player needs.
The config.lua
Config = {}
Config.Framework = 'qb' -- ('esx')
Config.FrameworkPseudo = 'qb-core' -- custom framework name ('es_extended')
Config.Target = "ox" -- 'qb' or 'ox' or 'interact' (-- interact is not recommended)
Config.Inventory = 'ox' -- 'qb', 'qs', 'tgiann' (you can add yours under client/inventories and server/inventories)
Config.Currency = '$' -- '$' or 'β¬' or 'Β£' or 'Ψ―.Ψ₯'
Config.debug = false -- prints washing data logs
Config.Tax = 18.0 -- tax on items (0.0 = 0%, 0.05 = 5%, 0.1 = 10%, etc.)
-- IMAGE DIRECTOTY :
-- "qb-inventory/html/images/" : qb-inventory (only qb)
-- "ox_inventory/web/images/" : ox-inventory (qb + esx)
-- "origen_inventory/web/images/" : origen_inventory (only qb)
-- "ps-inventory/html/images/" : ps-inventory (only qb)
-- "qs-inventory/html/images/" : qs-inventory (only qb)
-- "codem-inventory/html/itemimages/" : codem-inventory(only qb)
Config.Img = "ox_inventory/web/images/"
Config.Stand = {
prop = 'prop_shop_stand',
item = 'shop_stand',
}
Config.ShowLastestData = true -- if false then show all data (Latest will save only the last 6 transactions, items, etc. for performance)
Config.Types = {
['food'] = 'linear-gradient(#832935, #0a1d2e00)',
['drinks'] = 'linear-gradient(#5b2983, #0a1d2e00)',
['others'] = 'linear-gradient(#2e7085, #0a1d2e00)',
}
Config.Blacklist = {
'money',
'markedbills',
'shop_stand',
}
Config.Shops = {
['247supermarket'] = {
['label'] = '24/7 Supermarket',
['coords'] = vector4(24.47, -1346.62, 29.5, 271.66),
['ped'] = 'mp_m_shopkeep_01', -- nil in case you don't want a ped
['scenario'] = 'WORLD_HUMAN_STAND_MOBILE',
['radius'] = 1.5,
['showblip'] = true,
['blipsprite'] = 52,
['blipscale'] = 0.6,
['blipcolor'] = 0,
['stocklimit'] = 150, -- limit for countable products in the shop (nil = infinite -> it does not count)
['jobs'] = {}, -- you can adjust it to your jobs script under client/framework.lua | example ['jobs'] = {'mechanic'},
['gangs'] = {}, -- you can adjust it to your gangs script under client/framework.lua | example ['gangs'] = {'ballas'},
['permissions'] = {}, -- this is to give permissions to have access to SELL items inside this shop (keep it empty {} to allow everyone)
['products'] = {
{
item = 'tosti',
description = 'A tasty tosti sandwich.',
label = 'Tosti',
img = 'nui://'..Config.Img..'tosti.png',
price = 2,
type = 'food',
amount = nil,
metadata = {},
},
{
item = 'water_bottle',
description = 'Refreshing water bottle.',
label = 'Water Bottle',
img = 'nui://'..Config.Img..'water_bottle.png',
price = 2,
type = 'drinks',
amount = nil,
metadata = {},
},
{
item = 'kurkakola',
description = 'Kurka Kola soda.',
label = 'Kurka Kola',
img = 'nui://'..Config.Img..'kurkakola.png',
price = 2,
type = 'drinks',
amount = nil,
metadata = {},
},
{
item = 'twerks_candy',
description = 'Sweet twerks candy.',
label = 'Twerks Candy',
img = 'nui://'..Config.Img..'twerks_candy.png',
price = 2,
type = 'food',
amount = nil,
metadata = {},
},
{
item = 'snikkel_candy',
description = 'Snikkel candy for a quick treat.',
label = 'Snikkel Candy',
img = 'nui://'..Config.Img..'snikkel_candy.png',
price = 2,
type = 'food',
amount = nil,
metadata = {},
},
{
item = 'sandwich',
description = 'A delicious sandwich.',
label = 'Sandwich',
img = 'nui://'..Config.Img..'sandwich.png',
price = 2,
type = 'food',
amount = nil,
metadata = {},
},
{
item = 'beer',
description = 'A cold beer.',
label = 'Beer',
img = 'nui://'..Config.Img..'beer.png',
price = 7,
type = 'drinks',
amount = nil,
metadata = {},
},
{
item = 'whiskey',
description = 'Fine whiskey.',
label = 'Whiskey',
img = 'nui://'..Config.Img..'whiskey.png',
price = 10,
type = 'drinks',
amount = nil,
metadata = {},
},
{
item = 'vodka',
description = 'Strong vodka.',
label = 'Vodka',
img = 'nui://'..Config.Img..'vodka.png',
price = 12,
type = 'drinks',
amount = nil,
metadata = {},
},
{
item = 'bandage',
description = 'Bandage for minor injuries.',
label = 'Bandage',
img = 'nui://'..Config.Img..'bandage.png',
price = 100,
type = 'others',
amount = nil,
metadata = {},
},
{
item = 'lighter',
description = 'Lighter for smoking.',
label = 'Lighter',
img = 'nui://'..Config.Img..'lighter.png',
price = 2,
type = 'others',
amount = nil,
metadata = {},
},
{
item = 'rolling_paper',
description = 'Rolling paper for cigarettes.',
label = 'Rolling Paper',
img = 'nui://'..Config.Img..'rolling_paper.png',
price = 2,
type = 'others',
amount = nil00,
metadata = {},
},
}
},
['ltdgasoline'] = {
['label'] = 'LTD Gasoline',
['coords'] = vector4(1697.87, 4922.96, 42.06, 324.71),
['ped'] = 'mp_m_shopkeep_01', -- nil in case you don't want a ped
['scenario'] = 'WORLD_HUMAN_STAND_MOBILE',
['radius'] = 1.5,
['showblip'] = true,
['blipsprite'] = 52,
['blipscale'] = 0.6,
['blipcolor'] = 0,
['stocklimit'] = 150, -- limit for countable products in the shop (nil = infinite -> it does not count)
['jobs'] = {}, -- you can adjust it to your jobs script under client/framework.lua | example ['jobs'] = {'mechanic'},
['gangs'] = {}, -- you can adjust it to your gangs script under client/framework.lua | example ['gangs'] = {'ballas'},
['permissions'] = {}, -- this is to give permissions to have access to SELL items inside this shop (keep it empty {} to allow everyone)
['products'] = {
{
item = 'water_bottle',
description = 'Delicious tacos from Los Vantos Delicious tacos from Los Vantos Delicious tacos from Los Vantos Delicious tacos from Los Vantos',
label = 'Water Bottle',
img = 'nui://'..Config.Img..'water_bottle.png',
price = 226.99,
type = 'drinks',
amount = nil, -- infinite
metadata = {},
},
},
},
}
------------------------------------------------------------------------------------------------------------------------------------------------
------------------------------------------------------------------------------------------------------------------------------------------------
--------------------------------------------------------OPTIMISATION PART ----------------------------------------------------------------------
------------------------------------------------------------------------------------------------------------------------------------------------
------------------------------------------------------------------------------------------------------------------------------------------------
-- Description : this part is responsable on deleting the not needed props when no players are nearby
-- refreshprops : is the time to check if there is someone near the props or not
-- radius : is to check how far is the player from the prop if it is < then the prop will be deleted until someone is nearby...
Config.UseBuckets = false -- Keep it false unless you want to use props inside the apartments and houses that uses buckets (instance) (Not Recommended)
Config.RefreshProps = 15 -- 15 seconds
Config.Radius = 300.0 -- if the distance between the player and the prop is < 50 then the prop will be deleted.
Last updated