Skip to main content

Garage Integration

A garage that spawns a player's owned vehicle should register the entity and only issue a key when the garage intentionally wants to hand one to the player.

Server example:

local netId = NetworkGetNetworkIdFromEntity(vehicle)
exports.nord_vehiclekeys:RegisterOwnedVehicle(netId)
exports.nord_vehiclekeys:GiveKeys(source, plate)

If the garage stores the vehicle and should remove the currently issued key:

exports.nord_vehiclekeys:RemoveKeys(source, plate)

Do not create an insecure client event that accepts an arbitrary source and plate and forwards them directly to GiveKeys.