- Documentation
- Server functions
- getVehicleComponentRotation
Function
getVehicleComponentRotation
Returns the part rotation stored with setVehicleComponentRotation (0, 0, 0 when not set).
Syntax
float, float, float getVehicleComponentRotation(vehicle vehicle, string component)Arguments
vehiclevehicle- The vehicle.
componentstring- Part name.
Differences from MTA:SA
- These MTA:SA arguments are not here:
string base = "parent"
In MTA:SA
getVehicleComponentRotation(vehicle theVehicle, string theComponent, string base = "parent")Returns
Rotation x, y, z in degrees.
Example
local vehicle = createVehicle(411, 2000, -1690, 13.5)
local rx = getVehicleComponentRotation(vehicle, "bonnet_dummy")