FiveM Inventories

Sonoran Radio integrates with FiveM inventory systems for physical radio and scanner items.

QBCore

QBCore inventory support for the radio and radio scanner items is automatically detected.

Configuration

Inventory Restriction

To restrict radio and scanner access to users with the radio item in their inventory, set config.enforceRadioItem to true.

Inventory Item

Customize your radio and scanner items in your config.lua's Config.RadioItem and Config.ScannerItem objects.

Config.Lua Properties
-- Located in the Radio's config.lua
Config.RadioItem = {		 -- Note: Changes to this item will require a server restart to take effect
	name = 'sonoran_radio',  -- Item name in your inventory | STRING
	label = 'Sonoran Radio', -- Label for the item in your inventory | STRING
	weight = 1, 			 -- Weight of the item in your inventory | INT
	description = 'Communicate with others through the Sonoran Radio', -- Description of the item in your inventory | STRING
}
Config.ScannerItem = {
	name = 'sonoran_radio_scanner', -- Item ID
	label = 'Sonoran Radio Scanner', -- Label for the item in your inventory
	weight = 1, -- Weight of the item in your inventory
	description = 'Listen to radio chatter with the Sonoran Radio Scanner', -- Description of the item in your inventory
}

Supported Inventories (QBCore)

Currently, the following QBCore inventories are supported:

  • QBCore Inventory

  • OX Inventory

  • QS Inventory

Qbox

Configuration

Inventory Restriction

To restrict radio and scanner access to users with the radio item in their inventory, set config.enforceRadioItem to true.

Inventory Item

Qbox requires you to manually add the following to your /ox_inventory/data/items.lua file. The config.lua's Config.RadioItem and Config.ScannerItem can not be used with Qbox.

Ox Inventory Items File
['sonoran_radio_scanner'] = {
        label = 'Sonoran Radio Scanner',
        description = 'Listen to radio chatter with the Sonoran Radio Scanner',
        weight = 1,
        client = {
            image = 'radio.png',
            remove = function(total)
                if total < 1 then
                    TriggerServerEvent('SonoranRadio::DropItem::Scanner')
                end
            end
        }
    },
    ['sonoran_radio'] = {
        label = 'Sonoran Radio',
        description = 'Communicate with others through the Sonoran Radio',
        weight = 1,
        client = {
            image = 'radio.png'
        }
    },

Supported Inventories (Qbox)

Currently, the following Qbox inventories are supported:

  • OX Inventory

Known Issues and Limitations

OX Inventory

OX Inventory Bugs and Limitations

QS Inventory

QS Inventory Bugs and Limitations

Official Support

While QS inventory has not been officially tested with Sonoran Radio, customers have reported it working with full functionality. Report any issues on our support website.

Last updated

Was this helpful?