Struct TrackedTransform
Component tracking the current and previous poses of a transform at a fixed timestep
Inherited Members
Namespace: Unity.CharacterController
Syntax
[Serializable]
public struct TrackedTransform : IComponentData, IQueryTypeParameter
Fields
CurrentFixedRateTransform
Current transform
Declaration
[HideInInspector]
public RigidTransform CurrentFixedRateTransform
Field Value
Type | Description |
---|---|
RigidTransform |
PreviousFixedRateTransform
Previous transform
Declaration
[HideInInspector]
public RigidTransform PreviousFixedRateTransform
Field Value
Type | Description |
---|---|
RigidTransform |
Methods
CalculatePointDisplacement(float3)
Calculate a point that results from moving a given point from the previous transform to the current transform
Declaration
public float3 CalculatePointDisplacement(float3 point)
Parameters
Type | Name | Description |
---|---|---|
float3 | point | The point to move |
Returns
Type | Description |
---|---|
float3 | The moved point |
CalculatePointVelocity(float3, Single)
Calculates the linear velocity of a point that gets moved from the previous transform to the current transform over a time delta
Declaration
public float3 CalculatePointVelocity(float3 point, float deltaTime)
Parameters
Type | Name | Description |
---|---|---|
float3 | point | The point to move |
Single | deltaTime | The time delta |
Returns
Type | Description |
---|---|
float3 | The calculated linear velocity |