Real Wallet / Guides
Shops & the starter wallet
Selling wallets in a shop
install/shops.lua has a line for every wallet. Add the ones you want to a shop's inventory list in
ox_inventory/data/shops.lua, for example the General store:
Lua
General = {
name = 'Shop',
inventory = {
-- ... the shop's own items ...
{ name = 'wallet_matte', price = 150 },
{ name = 'wallet_gunmetal', price = 150 },
{ name = 'wallet_silver', price = 150 },
{ name = 'wallet_crimson', price = 150 },
{ name = 'wallet_rose', price = 165 },
{ name = 'wallet_olive', price = 165 },
{ name = 'wallet_titanium', price = 240 },
{ name = 'wallet_leather_black', price = 135 },
{ name = 'wallet_leather_espresso', price = 135 },
{ name = 'wallet_leather_cognac', price = 135 },
{ name = 'wallet_leather_oxblood', price = 135 },
{ name = 'wallet_leather_navy', price = 135 },
{ name = 'wallet_leather_forest', price = 135 },
{ name = 'wallet_leather_blush', price = 135 },
{ name = 'wallet_leather_stone', price = 135 },
},
-- ...
},
- The prices are suggestions; set your own.
- Leave out any wallet or colour you turned off in
config.lua. - With
Config.OnePerPlayer = true, a player who already carries a wallet can not buy another ("You already carry a wallet."), and a shop sells one wallet at a time.
A wallet for every character
Lua
Config.Starter = { enabled = true, give = true, item = 'wallet_matte', moveCards = false, delayMs = 6000 }
With enabled = true, every character gets a wallet once: the first time they load in after you turn it on, and for
players already online, when the resource starts.
- A character who already carries a wallet is not given another.
moveCards = truealso puts the cards they carry into it ("Your cards are in your wallet. Use it to take it out."). Otherwise they get "You have a wallet now. Use it to take it out."delayMswaits after the character loads, so your framework's own starter items are given first.- No room in their inventory? Nothing is given, and they get it on a later load.
Leave it off if your framework's starter items (for example qbx_core's or qb-core's) already include a wallet. To give one there instead, add the wallet item to the framework's starter items.
Giving a wallet by hand
Wallets are ordinary items, so any admin menu, job reward or script can give one:
Lua
exports.ox_inventory:AddItem(source, 'wallet_leather_cognac', 1)
A new wallet gets its id and empty storage the first time it is used.
Still stuck? Open a ticket in the Ryan Studios Discord and we'll help you out.