Description
The DeaccelerationTime
property specifies the amount of time, in seconds, it takes for the player to reduce their speed from the current speed to a lower requested speed. This property is useful for controlling how quickly a player can slow down, providing a smoother transition when decelerating.
Usage
To adjust the deacceleration time for a player, set the DeaccelerationTime
property on the PlayerController
instance. This will affect how quickly the player can slow down to a lower speed.
Example
// Example of setting the DeaccelerationTime property
PlayerController playerController = new PlayerController();
playerController.DeaccelerationTime = 1.5f; // Set deacceleration time to 1.5 seconds