zpx-banking
Installation guide for zorpex banking system
IMPORTANT
This script automatically inserts the database tables, eliminating the need to run the SQL code provided. If you encounter issues with the automated installation, consider manually running the sql instead.
DEPENDENCIES
QBCORE ONLY
Add the following item on qb-core/shared/items.lua:
bankcard = { name = 'bankcard', label = 'Bank Card', weight = 0, type = 'item', image = 'bankcard.png', unique = true, useable = true, shouldClose = true, combinable = nil, description = 'Used to access ATM' },
Search for this function on qb-core/server/player.lua:
function self.Functions.SetPlayerData(key, val)
if not key or type(key) ~= 'string' then return end
self.PlayerData[key] = val
self.Functions.UpdatePlayerData()
end
And under that, add the following code:
function self.Functions.ChangePlayerAccount(account)
self.PlayerData.charinfo.account = account
self.Functions.UpdatePlayerData()
end
ESX ONLY
Add the following item on the database:
INSERT INTO `items` (`name`, `label`, `weight`, `rare`, `can_remove`) VALUES ('bankcard', 'Bank Card', 1, 1, 1)
Last updated