📋Exports & Events

All exports and events available to integrate this resource into others.

Server Sided Exports

Transfer State

If you are using a plate switcher script, make sure to trigger the export in server/functions.lua when switching plates. If you don't do this, individuals can abuse the plate switcher script and continuously change plates and steal the catalytic converter over and over again.

Example:

---@param oldPlate string
---@param newPlate string
exports["zyke_catalytic"]:SwapPlates(oldPlate, newPlate)

Server Sided Events

Repair Vehicles

To repair a vehicle and reset the effects of the stolen catalytic converter, you need to run this event.

Example:

-- Example from the client side:
local vehicle = GetVehiclePedIsIn(PlayerPedId(), false)
local netId = NetworkGetNetworkIdFromEntity(vehicle)

---@param netId number
TriggerServerEvent("zyke_catalytic:Repair", netId)

Last updated