Shared
createSingleVehicle
exports.tr_kit.createSingleVehicle(settings)Parameters
- settings
object:Options
Return
- netId
number: the net id of the created vehicle
createMultipleVehicles
exports.tr_kit.createMultipleVehicles(vehicles, defaultSettings)Parameters
- vehicles
arrayofOptions - defaultSettings
object:Options
Return
- netIds
array: the net ids of the created vehicles
clearCreatedVehicle
exports.tr_kit.clearCreatedVehicle(netId)Parameters
- netId
number: the net id of the vehicle to delete
Return
- success
boolean: whether or not the vehicle was removed
clearCreatedVehicles
exports.tr_kit.clearCreatedVehicles(netIds)Parameters
- netIds
arrayofnumber: the net ids of the vehicles to delete
Return
- success
boolean: whether or not the vehicles was deleted
Options
- hash
number: the hash of the entity - coords
object | array: the coordinations of the entity you want to create- object:
- {x:
number, y:number, z:number, w:number}
- {x:
- array:
- [
number,number,number,number]
- [
- object:
- preCreate
boolean(optional): whether or not to fade in the vehicle's alpha on creating it
Callouts
- If you wonder how to get the entity id (the handle), you can use
NetworkGetEntityFromNetworkId(netId)which it'll return the entity id. - Also you can do the opposite by using
NetworkGetNetworkIdFromEntitywhich will return the netId if it was networked. - Now we stoped allowing to pass whether or not you want the create to be networked or not since most of the time you are going to clear the entity after use.