Garages, keys & notify
Connect your own systems.
Garages
Bought vehicles are saved in owned_vehicles (owner, plate, vehicle, type, stored). Garage scripts that read this table show the vehicle without changes, e.g. esx_garage, jg-advancedgarages, cd_garage and okokGarage.
If your garage uses its own table, add the code to custom/server.lua:
function Bridge.onVehiclePurchased(src, data)
-- data.model, data.plate, data.price, data.shop, data.payment, data.vehicle
endBridge.onVehicleSold(src, data) runs after every sale.
Keys
Config.Keys = 'auto' detects wasabi_carlock. For any other key script set Config.Keys = 'custom' and add it to custom/client.lua:
function Bridge.custom.giveKeys(vehicle, plate)
exports['my_keys']:GiveKey(plate)
endNotify & help text
Config.Notify = 'custom' and in custom/client.lua:
function Bridge.custom.notify(message, kind, title)
exports['my_notify']:Show(title, message, kind, 4000)
endFor the "press E" hint set Config.HelpText = 'custom' and fill in Bridge.custom.showHelp / Bridge.custom.hideHelp.
The files in custom/ are not encrypted and stay yours on updates.
