Introducing Supreme Inventory - All In One Inventory System by CodeM

CFX 13

CodeM Supreme Inventory is a slot based inventory for QBX, QBCore and ESX, built on its own Lua core and written to drop straight in over ox_inventory: same database tables, same data/*.lua files, same exports, events and hooks. Every script on your server that already talks to ox_inventory keeps working the moment you swap it in, with nothing to import and no convars to translate.

On top of that it adds the things servers normally buy separately: clothing as real inventory items, an interactive 3D weapon attachment bench, containers, a crafting system, a market system, stashes, water damage, degradable items and an in-game admin panel.


A familiar inventory, reimagined

The layout is the one players already know: pockets on the left, the character with clothing boxes in the middle, whatever you opened on the right. The hotbar sits above the pockets, weight and slot counters run across the top, and category chips filter what you see.

Drag to move, drop on a matching stack to stack, double-click or Alt + click to use, Shift + click to send an item straight to the other panel. Both panels have a sort and stack button, a search box and a quantity toggle, so a stash, a bag or a car boot is tidied the same way as your pockets.


Customize your inventory

Every player themes their own inventory and the choice is saved on their client: 12 accent swatches plus any custom hex (the screenshot uses #16FDAD), glass or flat panels, rounded or square corners, character column on or off, ground panel always visible or not, three layouts (classic, hotbar, split) and a sound volume slider.

The server decides the defaults and what players may touch through Config.Panel. A locked option keeps the server default for everyone and its row disappears from the settings drawer, so you can hand out theming freely or lock the whole thing down.


Move, resize and tilt every panel

Panel placement mode lets a player drag each panel where they want it, scroll to resize, hold Shift and drag to tilt, and right-click a panel or a clothing column to flip it sideways. Clothing slots can be arranged the same way. /resetlayout puts everything back where it started.


Interactive weapon attachments

Weapons open into a dedicated attachment bench with the weapon rendered in 3D: drag to turn, wheel to zoom, double click to reset. Seven sockets are wired up - sight, muzzle, barrel, magazine, light, grip and other - and the header counts what is fitted.

Only the parts the player actually carries show up in the tray at the bottom, and every change previews on the model before they head back into the action. The card on the right shows the weapon name, its generated serial number, the ammo in it and a durability bar. Camera distance and the backdrop gradient are set in the config (Config.benchDepth, Config.benchBackdrop).


Built-in crafting system

Craft simple items straight from the inventory, or walk up to a crafting bench for the recipes that need specific tools and materials. Each recipe shows its ingredients, the required tool with its wear cost (the Lockpick in the screenshot takes 5 % off a hammer plus 5x Scrap Metal) and the craft time in seconds.

Every bench is configured on its own in data/crafting.lua: location, target zone, recipe list, job and grade requirements, and per-recipe chance. Config.quickCraft also gives players a quick-craft button next to the settings button that opens the first bench they are allowed to use, wherever they stand.


Built-in market system

No separate shop resource. Shops live in data/shops.lua with their own blips, ped or prop models, target zones, category chips and stock counts. Players click items to fill a cart at the bottom, adjust quantities and pay in one go from cash or bank.

Prices and stock are per shop, job and grade locks are supported, and Config.randomPrices gives every location its own prices up to 20 % either way so the same 24/7 does not cost the same across the map.


Containers built for roleplay

Any item can become a container with its own slots, weight limit and whitelist of what may go inside. A pizza box carries pizza slices, or it hides something a good deal less legal underneath.

During a search an officer only sees the box. Opening it is a decision they have to make, which is what makes smuggling, deliveries and evidence hiding work as roleplay instead of a stat check.


Built-in stash system

Stashes go anywhere on the server with their own slot count, weight limit and access rules: shared, per player, or locked to a job and a minimum grade. The personal locker in the screenshot is 70 slots and 70 kg.

Stashes are stored in the ox_inventory table exactly as ox_inventory stores them, so an existing database carries over untouched. Scripts can also register stashes at runtime or create temporary ones that are never written to the database.


Water damage system

Items can be given a water rule: swim with one in your pockets and after a few seconds the sea takes care of it. A phone turns into a broken phone, a power bank stops working, a cigarette is simply gone.

The rule is per item and can name a replacement item, a count, a chance and metadata for what comes back. Config.water sets the delay (default 3 seconds), whether only diving counts, and whether the player is told. It is all resolved on the server, and a ruined item is a normal inventory change, so hooks and Discord logs see it like any other.


Degradable items

Items can carry a durability that ticks down over time. The tooltip shows the current percentage and the degrade value, and when it reaches zero the item either disappears or turns into whatever you configured. Food, medical supplies and documents all behave the way players expect them to.


Drag and combine crafting

Some recipes do not need a bench at all. Drag one item onto another and, if they are compatible, a progress bar runs and a new item comes out. Rolling paper plus weed makes a joint. Each combination defines its own result, duration and reward count in the item definition.


Personalize items for roleplay

The right-click menu carries everything an item can do: Inspect, Use, Give, Attachments, Copy serial number, Rename, Write a note, Throw, Put down, Position and Drop.

Rename a stolen weapon with its previous owner’s name, leave a note inside a briefcase, add a message to a gift. Renaming is configured per item and can cost money, and a custom picture URL is allowed up to Config.maxImageLength characters.


Detailed item inspection

Hovering any slot shows its details straight away: label, type, weight, count, durability, rarity tier and every metadata row the item defines. Right-click and Inspect opens the larger card. Metadata layouts are set per item type in data/metadata.lua, so an ID card reads like an ID card and a weapon reads like a weapon.

Rarity is a colour tier on the slot plus a label in the tooltip. 19 tiers ship in the config, from common to mythic plus 13 item-type tiers such as Firearm, Police Item and Crafting Item, and you can add or rename them freely.


Clothing as items

Hat, glasses, earrings, mask, top, pants, shoes, bag, chain, watch, bracelet, badge, vest garment and bulletproof vest are real items that live in the wear boxes around the character. Outfit bags and outfit sets, personal wardrobes and taking clothes off a searched player are all included, and hair and face can be hidden under hats and masks.

Armour is its own thing: a vest holds armour points (max 100 by default), heavy and light plates fill it, strapping one on takes 20 seconds, and damage taken in a fight is written back to the vest, so a used vest stays used.

The ped is dressed through codem-lib, which recognises codem-clothing, illenium-appearance, fivem-appearance, qs-appearance, 4bit_appearance, qf_skinmenu, crm-appearance, tgiann-clothing, rcore_clothing, 0r-clothing, qb-clothing and esx_skin / skinchanger on its own. Anything else is wired up with a few client hooks.


The rest of the world

  • Weapons - durability, ammo as items, serial numbers with a custom pattern, tints, auto reload and aimed firing options, weapon mismatch guard, and up to 3 carried weapons drawn on the body across back, front, leg and waist mounts.
  • Repair workshops - basket, cash or bank payment, progress bar, nothing charged if the player cancels.
  • Give by hand - the item comes into your hand, you aim at a player, they accept or decline within 10 seconds. Drivers can be handed things through the window.
  • Player search - /steal checks dead, cuffed and hands-up states on the server, reads hands-up animations for scripts that set no flag, requires a weapon and exempts police jobs.
  • Throwing and placing - aim marker up to 60 m, throw power by item weight, and a ghost prop placement mode with rotate, tilt, free move and ground snap.
  • Ground piles - the prop follows the weight of the pile: paper bag, cardboard box or wooden crate.
  • Carrying - a TV or a box is held in both arms, the player walks slower and cannot sprint or draw a weapon.
  • Vehicles - trunk and glovebox sized per vehicle class and per model, following the game’s own door lock state.
  • Evidence lockers and licences, random loot in unowned vehicles and 60+ dumpster models with search times and cooldowns.
  • Admin panel - /invadmin opens any player or vehicle inventory, gives items with metadata, clears inventories, shows who holds an item online or offline, and fetches missing item pictures from public collections.

:gear: Technical Details

Frameworks QBX (qbx_core), QBCore (qb-core), ESX (es_extended) - auto detected
Dependencies oxmysql, codem-lib. ox_lib is not required
Server build 6116 or newer, OneSync on
Database ox_inventory table plus the framework’s own inventory, trunk and glovebox columns. Nothing to import - missing columns and indexes are created on first start
Compatibility Provides ox_inventory. Same exports, events and hooks, plus qb-inventory event support and PlayerData.items sync
Migrations codem-inventory v1, tgiann-inventory, tgiann bags. Guides for ox_inventory and qb-inventory
Target ox_target or qb-target, with marker and [E] fallback
Commands 24, all renameable or removable from one file
Logs 8 Discord webhook categories, plus a per-action abuse guard
Performance ~0.02 ms per add or remove, PlayerData pushes folded into one per 150 ms per player, /invperf and /invtest built in
Open files shared/config.lua, shared/commands.lua, shared/clothing.lua, shared/discordlog.lua, data/*.lua, locales/*.json, clothingitems/, migration/*.lua, client/exports.lua
Escrow Core Lua and the UI are protected, everything listed above stays editable

Showcase


Get It Now

Tebex


Documentation


Need support ? Join CodeM’s Discord Channel

Code is accessible No
Subscription-based No
Lines (approximately) 16500-20000
Requirements QBCore, QBox, ESX
Support Yes
1 Like