Character Controller Pro 1.4.11
A 2D/3D character controller asset for Unity.
Lightbug.CharacterControllerPro.Core.CharacterConstants Class Reference

This class contain all the constants used for collision detection, steps detection, ground probing, etc. All the values were carefully chosen, this means that it is not recommended to modify these values at all, however if you need to do it do so at your own risk (make a backup before). More...

Static Public Attributes

const float GroundTriggerOffset = 0.05f
 Offset (towards the ground) applied to the ground trigger.
 
const float MaxUnstableGroundContactTime = 0.25f
 This value represents the time (in seconds) that a jumping character can remain unstable while touching the ground. This becomes useful to prevent the character to be stuck in this unstable state for too long.
 
const float EdgeRaysSeparation = 0.005f
 Distance between the origins of the upper and lower edge detection rays.
 
const float EdgeRaysCastDistance = 2f
 Cast distance used for the raycasts in the edge detection algorithm.
 
const float SkinWidth = 0.005f
 Space between the collider and the collision shape (used by physics queries).
 
const float ColliderMinBottomOffset = 0.1f
 Minimum offset applied to the bottom of the capsule (upwards) to avoid contact with the ground.
 
const float MinEdgeAngle = 0.5f
 Minimum angle between upper and lower normals (from the edge detector) that defines an edge.
 
const float MaxEdgeAngle = 170f
 Maximum angle between upper and lower normals (from the edge detector) that defines an edge.
 
const float MinStepAngle = 85f
 Minimum angle between upper and lower normals (from the edge detector) that defines a step.
 
const float MaxStepAngle = 95f
 Maximum angle between upper and lower normals (from the edge detector) that defines a step.
 
const float GroundCheckDistance = 0.1f
 Base distance used for ground probing.
 
const int MaxSlideIterations = 3
 Maximum number of iterations available for the collide and slide algorithm.
 
const int MaxPostSimulationSlideIterations = 2
 Maximum number of iterations available for the collide and slide algorithm used after the simulation (dynamic ground processing).
 
const float DefaultGravity = 9.8f
 The default gravity value used by the weight function.
 
const float HeadContactMinAngle = 100f
 Minimum angle value considered when choosing the "head contact". The angle is measured between the contact normal and the "Up" vector. The valid range goes from "MinHeadContactAngle" to 180 degrees.
 
const float WallContactAngleTolerance = 10f
 Tolerance value considered when choosing the "wall contact". The angle is measured between the contact normal and the "Up" vector. The valid range goes from 90 - "WallContactAngleTolerance" to 90 degrees.
 
const float GroundPredictionDistance = 10f
 Distance used to predict the ground below the character.
 

Detailed Description

This class contain all the constants used for collision detection, steps detection, ground probing, etc. All the values were carefully chosen, this means that it is not recommended to modify these values at all, however if you need to do it do so at your own risk (make a backup before).


The documentation for this class was generated from the following file: