
🧩Props
Adding More PROPS
- Adding more props that bars can use is very simple via the - config.luafile
- To add another prop that a shop can use you must pass the - shopNameas the key and then customize the values to suit your needs
- To add another prop simply add your - shopNameas they- keyand then customize the- valuesto suit your server needs in- Config.Propsplease note some target interactions for props and require args passing with the target
- to disable a prop if you are not using that location or that prop then change - Enabled= trueto- Enabled = falsethis will then disable that specific prop and will not spawn it
Sometimes props can seem to not appear to spawn where you want them too.
There could be a couple of reasons for this:
- The prop model you have used is incorrect or unrecognised 
- If using custom props ensure these are being streamed in your server correctly and prop names match 
- Some MLO collisions are scuffed meaning props fall through them due to the native - PlaceObjectOnGroundProperly()being used in this script.
In these cases consider using target zones instead to interact with the specific event you are wanting to use a prop for. You can pass the same data and args to the target table as you would with the props table
Config.Props = {
    ['Example Shop'] = {
        { 
            Enabled = true,
            Model = 'prop_cs_silver_tray',
            Coords = vector4(378.68, -827.42, 30.28, 0.0),
            Icon = 'fa-solid fa-box',
            Label = 'Open Collection Tray',
            Job = nil,
            Distance = 3.0,
            Event = 'lusty94_weedshops:client:OpenTray',
            args = { shopName = "Example Shop", storageType = "CollectionTray" }, --[[ ✅ Make Sure To Pass shopName For storage and the storageType you define in Config.CoreSettings.Stashes]]
        },
        { 
            Enabled = true,
            Model = 'xm_prop_x17_computer_01',
            Coords = vector4(375.65, -824.39, 30.09, 180),
            Icon = 'fa-solid fa-box',
            Label = 'Open Management Menu',
            Job = Config.CoreSettings.Jobs['Example Shop'].name, 
            Distance = 3.0,
            Event = Config.CoreSettings.EventNames.BossMenu,
        },
        { 
            Enabled = true,
            Model = 'prop_cctv_cont_02',
            Coords = vector4(376.87, -824.59, 30.15, 180.0),
            Icon = 'fa-solid fa-box',
            Label = 'View CCTV',
            Job = Config.CoreSettings.Jobs['Example Shop'].name, 
            Distance = 3.0,
            Event = 'lusty94_weedshops:client:OpenCCTVMenu',
            args = { shopName = "Example Shop" }, --[[ ✅ Make Sure To Pass shopName For CCTV MENU]]
        },
    },
}Some target locations for props and box zones will need argspassing with them for various events to determine which shopis accessing that function
⚠️ The ShopName args must match the ShopName key 
--this is a target example for opening the supplies menu which needs the shopName argument passed
{
    Enabled = true,
    Name = "exampleshop_supplies",
    Location = vector3(383.46, -827.29, 29.29),
    Size = vec3(2.5,0.5,2),
    Width = 0.5, Height = 2.5, Heading = 270,
    MinZ = 28.5, MaxZ = 30.5, Distance = 2.0,
    Icon = 'fa-solid fa-hand-point-up', Label = 'Get Supplies',
    Job = Config.CoreSettings.Jobs['Example Shop'].name,
    Event = 'lusty94_weedshops:client:GetSupplies',
    args = { shopName = 'Example Shop' }, --[[ ✅ Make Sure To Pass shopName For supplies menu ]]
},  
Last updated
