Creating add-on components
You can write Unity components requiring a VehiclePhysics.VehicleBase
component for adding or modifying the vehicle's behavior. Requiring
VehicleBase makes the add-on
component compatible with any vehicle controller, including custom vehicle controllers.
You can interact with the vehicle with these properties exposed at VehicleBase:
Access to the internal Data Bus, which provides a lot of internal information that can be read and modified.
Some add-ons included in VPP as example:
- Access to the individual states of each wheel. There's a lot of information per wheel available here. For example, the VPAudio component reads the sliding state of each wheel here and produces the tire skid sound.
Additionally, you can read
optimized access to these components of the vehicle.