S&box Wiki

Transform

Transform

A struct containing a position, rotation and scale. This is commonly used in engine to describe entity position, bone position and scene object position.

Fields

Methods

Transform Add( Vector3 pos, bool worldspace )
Add a position this this transform and return the result.
static Transform Lerp( Transform a, Transform b, float t, bool clamp )
Lerp from one transform to another
Vector3 NormalToLocal( Vector3 worldNormal )
Convert a world normal to a local normal
Vector3 NormalToWorld( Vector3 localNormal )
Convert a local normal to a world normal
Vector3 PointToLocal( Vector3 worldPoint )
Convert a point in world space to a point in this transform's local space
Vector3 PointToWorld( Vector3 localPoint )
Convert a point in this transform's local space to a point in world space
Rotation RotationToLocal( Rotation worldRot )
Convert a world rotation to a local rotation
Rotation RotationToWorld( Rotation localRotation )
Convert a local rotation to a world rotation
Transform ToLocal( Transform child )
Convert child transform from the world to a local transform
Transform ToWorld( Transform child )
Convert child transform from local to the world
Vector3 TransformVector( Vector3 local )
Transform a Vector as if it were a child of this transform

Special Pages


Wikis

?

Render Time: 35ms

DB GetPage 25
Generate Html 0
SaveChanges (1) 7
Render Body 0
Render Sidebar 0