hydrus:vehicle-redeem
Este evento é disparado sempre que um crédito de veículo é resgatado, através desse evento você pode adicionar comportamento adicional.
interface Context {
credit: {
id: string
name: string
image: string
days?: number
has_testdrive?: boolean
form: Array<unknown[]
},
player_id: string | number // ID do jogador
source: number // Source do jogador
vehicle: string // Spawn do veículo resgatado
}
AddEventHandler('hydrus:vehicle-redeem', function(ctx)
local source = ctx.source
local id = ctx.player_id
local vehicle = ctx.vehicle
if ctx.credit.days then
-- Isso significa que o crédito é temporário
end
end)
Last updated