Modify Trigger Size
Description
Controls the dimension of the front trigger based on the vehicle's speed.
Declaration
public delegate void ModifyTriggerSize(float currentSpeed, BoxCollider frontCollider, float maxSpeed, float minTriggerLength, float maxTriggerLength);Parameters
Name
Description
currentSpeed
The current speed of the vehicle.
frontCollider
The front trigger to be modified.
maxSpeed
The maximum possible speed of the vehicle.
minTriggerLength
The minimum dimension allowed for the trigger, that was set inside the Vehicle Component.
maxTriggerLength
The maximum dimension allowed for the trigger, that was set inside the Vehicle Component.
Set Method
public static void SetModifyTriggerSize(ModifyTriggerSize modifyTriggerSizeDelegate, int vehicleIndex = -1)Example
Last updated