GKSHOP
Web StoreDiscord
  • 👋GKSHOP Documentation
  • INFORMATION
    • ⁉️FAQ
    • 💡Discord Roles
    • ⚠️FiveM Asset Escrow System
  • GKSPHONE v2
    • 📔Installation
    • ❓Documentation
    • 👷Exports
      • Client
      • Server
    • 🪛Custom App
    • Configuration
      • Unique phones
      • Custom inventory
      • Custom Wallpapers
      • Custom ringtones and notifications
      • Apps
      • Currency
    • Common Issues
    • 🚒Job Center
  • GKSPHONE v1
    • 📱ESX
      • 📔Installation
      • ❓Documentation
      • Application Usages
      • Developers
        • Server Event
        • Client Event
    • 📱QB
      • 📔Installation
      • ❓Documentation
      • Application Usages
      • Developers
        • Server Event
        • Client Event
  • Other Products
    • ⚒️GKSCRAFT
      • 📘Installation
      • Config
      • Developers
        • Server Event
    • ⛽GKS FUEL
      • 📔Installation
      • Config
      • Exports
    • 📸Media Services (GKSMEDIA)
    • 📲GKSPHONE Real App
  • OTHER
    • Policy
      • Privacy Policy
Powered by GitBook
On this page
  • What are unique phones?
  • Supported inventories
  • How do you enable unique phones?
  • How do you set up unique phones with your inventory?
  • ox_inventory
  • qb-inventory, core_inventory, qs-inventory, tgiann-inventory
  1. GKSPHONE v2
  2. Configuration

Unique phones

PreviousConfigurationNextCustom inventory

Last updated 4 months ago

What are unique phones?

A phone is bound to a phone item, not to a character.

Every phone is like a physical phone and can be used with all stored data.

You can give your phone to another player, and they can use it with all the data stored in it.

Supported inventories

An inventory with metadata is enough, but not all inventories are supported out of the box. If your inventory is not supported, see for a guide on how to implement it yourself.

  • - recommended

How do you enable unique phones?

To enable unique phones, you need to set Config.MetaItem to true in gksphone/config/config.lua.

Config.MetaItem = true

How do you set up unique phones with your inventory?

ox_inventory

Add the following to ox_inventory/data/items.lua. If you already have an item called "phone" and "iphone", replace the data.

["phone"] = {
	label = "Phone",
	weight = 190,
	stack = false,
	consume = 0,
	client = {
		export = "gksphone.UsePhoneItem",
		remove = function()
			TriggerEvent("gksphone:client:ItemRemoved", "phone")
		end
	}
},
["iphone"] = {
	label = "iPhone",
	weight = 190,
	stack = false,
	consume = 0,
	client = {
		export = "gksphone.UsePhoneItem",
		remove = function()
			TriggerEvent("gksphone:client:ItemRemoved", "iphone")
		end
	}
},

qb-inventory, core_inventory, qs-inventory, tgiann-inventory

Open qb-core/shared/items.lua and search for phone and iphone. Replace it with the following:

phone = { name = 'phone', label = 'Phone', weight = 700, type = 'item', image = 'phone.png', unique = true, useable = true, shouldClose = true, combinable = nil, description = 'Neat phone ya got there' },
iphone = { name = 'iphone', label = 'iPhone', weight = 1000, type = 'item', image = 'iphone.png', unique = true, useable = true, shouldClose = true, combinable = nil, description = 'Very expensive phone' },

custom inventory
ox_inventory
qb-inventory
core_inventory
qs-inventory
tgiann-inventory