Shop Account

Instructions on using mechanic shop account in other resources

The resource offers a custom account system that is standalone and not dependent on frameworks.

Get Shop ID

You can get the player's mechanic shop id with this export:

local src = source
local shopID = exports['t1ger_mechanicsystem']:GetPlayerMechId(src)
-- src(INT): player server id

Add Account Money

exports['t1ger_mechanicsystem']:PlusMechanicAccount(shopId, amount)
-- shopId(INT): mechanic shop id
-- amount(INT): amount of money to add to the account

Remove Account Money

exports['t1ger_mechanicsystem']:MinusMechanicAccount(shopId, amount)
-- shopId(INT): mechanic shop id
-- amount(INT): amount of money to add to the account

Usage - Example #1

Here's an example to easily add/remove money from a mechanic shop:

Usage - Example #2

Here's an alternative example using TriggerEvent (similar to esx_addonaccount)

Last updated