void ClearLerp()

book_4_sparkGenerated
code_blocksInput

Description

The ClearLerp method is part of the GameTransform class in the Sandbox API. This method is marked as obsolete and should not be used in new code. Instead, developers are advised to use the ClearInterpolation method, which serves a similar purpose.

Usage

Since ClearLerp is obsolete, it is recommended to replace its usage with ClearInterpolation in your codebase. The ClearInterpolation method clears any ongoing interpolation and forces the object to reach its final destination immediately. This is particularly useful in networked environments where you want to ensure that all clients have consistent object states.

Example

// Example of using ClearInterpolation instead of ClearLerp
GameTransform transform = new GameTransform();

// Clear any interpolation
transform.ClearInterpolation();