Interface IVehicleInfoService
Provides functionality for getting information about vehicle models and components.
public interface IVehicleInfoService
Methods
GetColorFromVehicleColor(int, uint)
Gets the Color representation of the specified vehicleColor.
Color GetColorFromVehicleColor(int vehicleColor, uint alpha = 255)
Parameters
Returns
GetComponentType(int)
Gets the car mod type of the specified componentId.
CarModType GetComponentType(int componentId)
Parameters
componentIdintThe identifier of the component.
Returns
- CarModType
The car mod type of the component.
Exceptions
- ArgumentOutOfRangeException
Thrown if the specified
componentIdis invalid.
GetModelInfo(VehicleModelType, VehicleModelInfoType)
Gets information of type specified by infoType for the specified vehicleModel.
Vector3 GetModelInfo(VehicleModelType vehicleModel, VehicleModelInfoType infoType)
Parameters
vehicleModelVehicleModelTypeThe model of the vehicle.
infoTypeVehicleModelInfoTypeThe type of information to get.
Returns
- Vector3
The information about the vehicle model.
GetPassengerSeatCount(VehicleModelType)
Gets the number of passenger seats in the specified vehicleModel.
int GetPassengerSeatCount(VehicleModelType vehicleModel)
Parameters
vehicleModelVehicleModelTypeThe model of the vehicle.
Returns
- int
The number of passenger seats excluding the driver seat.
GetRandomVehicleColor(VehicleModelType)
Gets a set of random colors for the specified vehicleModel as they would naturally appear in the game.
(int, int, int, int) GetRandomVehicleColor(VehicleModelType vehicleModel)
Parameters
vehicleModelVehicleModelTypeThe model of the vehicle.
Returns
IsValidComponentForVehicle(VehicleModelType, int)
Returns a value indicating whether the specified componentId is valid for the specified vehicleModel.
bool IsValidComponentForVehicle(VehicleModelType vehicleModel, int componentId)
Parameters
vehicleModelVehicleModelTypeThe model of the vehicle.
componentIdintThe component to check.