2025-07-11 19:05:45 -04:00
|
|
|
---@diagnostic disable: duplicate-set-field
|
|
|
|
|
if GetResourceState('tgg-banking') == 'missing' then return end
|
2025-07-25 02:51:14 -05:00
|
|
|
Banking = Banking or {}
|
2025-07-11 19:05:45 -04:00
|
|
|
|
|
|
|
|
local tgg = exports['tgg-banking']
|
|
|
|
|
|
|
|
|
|
---This will get the name of the Managment system being being used.
|
|
|
|
|
---@return string
|
2025-07-25 02:51:14 -05:00
|
|
|
Banking.GetManagmentName = function()
|
2025-07-11 19:05:45 -04:00
|
|
|
return 'tgg-banking'
|
|
|
|
|
end
|
|
|
|
|
|
|
|
|
|
---This will return a number
|
|
|
|
|
---@param account string
|
|
|
|
|
---@return number
|
2025-07-25 02:51:14 -05:00
|
|
|
Banking.GetAccountMoney = function(account)
|
2025-07-11 19:05:45 -04:00
|
|
|
return tgg:GetSocietyAccountMoney(account) or 0
|
|
|
|
|
end
|
|
|
|
|
|
|
|
|
|
---This will add money to the specified account of the passed amount
|
|
|
|
|
---@param account string
|
|
|
|
|
---@param amount number
|
|
|
|
|
---@param _ string
|
|
|
|
|
---@return boolean
|
2025-07-25 02:51:14 -05:00
|
|
|
Banking.AddAccountMoney = function(account, amount, _)
|
2025-07-11 19:05:45 -04:00
|
|
|
return tgg:AddSocietyMoney(account, amount)
|
|
|
|
|
end
|
|
|
|
|
|
|
|
|
|
---This will remove money from the specified account of the passed amount
|
|
|
|
|
---@param account string
|
|
|
|
|
---@param amount number
|
|
|
|
|
---@param _ string
|
|
|
|
|
---@return boolean
|
2025-07-25 02:51:14 -05:00
|
|
|
Banking.RemoveAccountMoney = function(account, amount, _)
|
2025-07-11 19:05:45 -04:00
|
|
|
return tgg:RemoveSocietyMoney(account, amount)
|
|
|
|
|
end
|
|
|
|
|
|
2025-07-25 02:51:14 -05:00
|
|
|
return Banking
|