💎Custom Currency in Pet Shop
💎Custom Currency in Pet Shop
NEW FEATURE! This feature is fully compatible with existing shops. Old shops will maintain their pet placed by default.
📋 Overview
The Custom Currency system lets you define shop items that are paid only with a currency of your choice (e.g. crypto from Qbox, or your own VIP/points). When an item uses customCurrency, the player pays only that currency—no cash is charged. The pet shop (NPC shop / Tab Shop) displays the custom currency balance in the header next to cash, with a diamond icon (or your own icon), and shows “Buy [Currency Name]” on the button.
Perfect for:
💎 VIP-only or premium items paid with a custom currency
🪙 Crypto or other in-game currencies
💰 Have profit on your server using our pet system.
✨ Key Features
📁 Custom currency per item
In shop.lua, set customCurrency = { crypto = 50 } (or your key). Item is paid only with that currency.
💰 Header balance
When the shop has custom-currency items, the header shows cash + custom currency balance (with icon).
📝 Single language key
The name shown (e.g. “Crypto”, “VIP Coins”) comes from vip_coins in data/languages—one key for all.
🔧 Optional custom icon
Use default diamond SVG or your own image via Shop.CustomCurrencyIcon in config.
🔃 Balance refresh after purchase
After a successful purchase, the shop reopens with updated cash and custom currency balance.
🔧 How Setup Custom Currency & Preview
1. Open the file api.lua located at: cdev_lib > public > server > api.lua
2. Inside this file, we will modify the three functions shown below.
Note: Since I am using QBox/QBCore, no changes are required. If you are using another VIP currency system, configure it correctly for QBCore/QBox or ESX.
3. Now open the file config.lua located at: cdev_pets > public > config > config.lua
We will add a pet-type product to be sold using a custom currency. Locate the product you want to edit.
⚠️ Important: The variable passed inside the customCurrency object will be the variable used by the functions in cdev_lib. e.g ( I use crypto from QBCore/Qbox )
Set price = 0 (recommended so it’s clear the item is custom-currency only).
4. (Optional) Change the Custom Currency name
⚠️ Attention: I will use the en.lua file as an example, but you can use any file inside cdev_pets/data/languages. After opening it, simply search for the variable named vip_coins.
⚠️ Attention: In the gift below, I only added it for one item, which is the Hotweiller pet, but you can apply this system to any pet or item (accessories).

❓ Frequently Asked Questions
Last updated