build Constructors 1

data_object Properties 85

AccelerationTime
float
Input smoothing for non-walking modes.
AimStrengthBody
float
How strongly to turn in the eye direction with our body
AimStrengthEyes
float
How strongly to look in the eye direction with our eyes
AimStrengthHead
float
How strongly to turn in the eye direction with our head
AirFriction
float
Airborne drag. Zero preserves strafing and surfing momentum.
AltMoveButton
string
The button that the player will press to use to run
Body
Rigidbody
BodyCollider
CapsuleCollider
BodyCollisionTags
TagSet
BodyHeight
float
BodyMass
float
BodyRadius
float
The feet-box width and upper capsule diameter.
BrakePower
float
We will apply extra friction when we're on the ground and our desired velocity is lower than our current velocity, so we will slow down.
CameraCollisionIgnore
TagSet
The set of tags to ignore during camera collision detection.
CameraOffset
Vector3
CastShadowsInFirstPerson
bool
Allow the body and its child models to cast shadows in first person, even when hidden.
ColliderObject
GameObject
ComponentVersion
int
CoyoteTime
float
How many seconds after leaving the ground the player can still jump. Set to 0 to disable.
CurrentHeight
float
Gets the current character height from Sandbox.PlayerController.BodyHeight when standing, otherwise uses Sandbox.PlayerController.DuckedHeight when ducking.
DeaccelerationTime
float
Deceleration smoothing for non-walking modes.
DuckButton
string
The button that the player will hold to duck. Leave empty to disable ducking input (ducking can still be driven from code via Sandbox.PlayerController.UpdateDucking(System.Boolean)).
DuckDuration
float
How many seconds it takes to crouch while on the ground. Set to 0 to crouch instantly.
DuckedHeight
float
DuckedSpeed
float
EnableFootstepSounds
bool
EnableJumpBoost
bool
Adds forward momentum when jumping from the ground at full sprint speed
EnablePressing
bool
Allows to player to interact with things by "use"ing them. Usually by pressing the "use" button.
EyeAngles
Angles
The direction we're looking in input space.
EyeDistanceFromTop
float
EyePosition
Vector3
The player's eye position, in first person mode
EyeTransform
Transform
The player's eye transform, in first person mode
FeetCollider
BoxCollider
FootstepMixer
MixerHandle
FootstepVolume
float
GroundComponent
Component
The collider component we're standing on. Null if we're standing nothing
GroundFriction
float
The friction property of the ground we're standing on.
GroundIsDynamic
bool
Are we standing on a surface that is physically dynamic
GroundNormal
Vector3
The normal of the walkable surface beneath us.
GroundObject
GameObject
The object we're standing on. Null if we're standing on nothing.
GroundSurface
Surface
The surface we're standing on.
GroundVelocity
Vector3
The velocity that the ground underneath us is moving
Headroom
float
The distance from the top of the head to the closest ceiling.
HideBodyInFirstPerson
bool
Hide the local player's body and its children in first person.
HoldToJump
bool
Keep jumping while the jump button is held, subject to the movement mode's jump limits.
Hovered
Component
The object we're currently looking at
IsAirborne
bool
Not touching the ground, and not swimming or climbing
IsClimbing
bool
Set to true when entering a climbing Sandbox.Movement.MoveMode.
IsDucking
bool
True if this player is ducking
IsOnGround
bool
IsSwimming
bool
Set to true when entering a swimming Sandbox.Movement.MoveMode.
JumpBoost
float
Extra momentum added when sprint jumping (as a fraction of RunSpeed)
JumpSpeed
float
LookSensitivity
float
Allows modifying the eye angle sensitivity. Note that player preference sensitivity is already automatically applied, this is just extra.
Mode
MoveMode
PitchClamp
float
Pressed
Component
The object we're currently using by holding down USE
ReachLength
float
How far from the eye can the player reach to use things
Renderer
SkinnedModelRenderer
The body will usually be a child object with SkinnedModelRenderer
RotateWithGround
bool
RotationAngleLimit
float
RotationSpeed
float
RunByDefault
bool
If true then the player will run by default, and holding AltMoveButton will switch to walk
RunSpeed
float
ShowArmsInFirstPerson
bool
When the body is visible in first person, also show the chest, arms, hands and anything held in them.
ShowColliderComponents
bool
ShowCreateBodyRenderer
bool
If true we'll show the "create body" button
ShowRigidbodyComponent
bool
StepDebug
bool
Enable debug overlays for this character.
ThirdPerson
bool
TimeSinceGrounded
TimeSince
Amount of time since this character was last on the ground
TimeSinceUngrounded
TimeSince
Amount of time since this character was last not on the ground
ToggleCameraModeButton
string
Tooltips
List`1
The tooltip of the currently hovered Pressable object
UnduckDuration
float
How many seconds it takes to stand back up while on the ground. Set to 0 to stand instantly.
UseAnimatorControls
bool
UseButton
string
The button that the player will press to use things
UseCameraControls
bool
UseFirstPersonAnimation
bool
Disable this when the first person pose doesn't suit the situation, like sitting in a seat where it leans the back into it.
UseFovFromPreferences
bool
UseInputControls
bool
UseLookControls
bool
When true we'll move the camera around using the mouse
Velocity
Vector3
Our actual physical velocity minus our ground velocity
WalkSpeed
float
WishVelocity
Vector3

Inheritance

edited 7 months ago#1
bolo
Member
JoinedApr 2026 Posts1 Score0
Sыr
Member
JoinedMar 2026 Posts4 Score205
I wish this wasn't a sealed class. Inside it, lots of values are hard-coded (like the check for jumping). I wanted to get a simple CanJump() method but hit a brick wall. 
nt
Member
JoinedJul 2023 Posts5 Score2,215
I wanted to apply impulse to Rigidbody on a Player Controller. I was tweaking and about to do 10 backflips. So if you ever get in that situation remember about PreventGrounding()   and apply shitton of force on that sausage, boy is heavy.
people
Log in to reply
You can't reply if you're not logged in. That would be crazy.