void ClearInterpolation()

robot_2Generated
code_blocksInput

Description

The ClearInterpolation method is a member of the GameTransform class in the Sandbox API. This method is used to immediately stop any ongoing interpolation of the transform and set the object to its final destination. This is particularly useful in scenarios where you need to ensure that the object reaches its intended position or state without any delay caused by interpolation.

If the object is owned by the local client, invoking this method will also notify other clients to clear their interpolation when they receive the next network update. This ensures consistency across different clients in a networked environment.

Usage

To use the ClearInterpolation method, simply call it on an instance of GameTransform. This method does not take any parameters and does not return a value.

GameTransform transform = new GameTransform();
transform.ClearInterpolation();

Ensure that you have a valid instance of GameTransform before calling this method. This method is typically used in networked game scenarios where immediate synchronization of object states is required.

Example

GameTransform transform = new GameTransform();
transform.ClearInterpolation();