Public Member Functions
|virtual PX_INLINE bool||isValid () const|
|returns true if the current settings are valid |
|getType () const|
|Returns the character controller type. |
|The position of the character. |
|Specifies the 'up' direction. |
|The maximum slope which the character can walk up. |
|Height of invisible walls created around non-walkable triangles. |
|Maximum height a jumping character can reach. |
|The contact offset used by the controller. |
|Defines the maximum height of an obstacle which the character can climb. |
|Density of underlying kinematic actor. |
|Scale coefficient for underlying kinematic actor. |
|Cached volume growth. |
|Specifies a user report callback. |
|Specifies a user behavior callback. |
|The non-walkable mode controls if a character controller slides or not on a non-walkable part. |
|The material for the actor associated with the controller. |
|Use a deletion listener to get informed about released objects and clear internal caches if needed. |
|User specified data associated with the controller. |
Protected Member Functions
|constructor sets to default. |
|virtual PX_INLINE||~PxControllerDesc ()|
|PX_INLINE||PxControllerDesc (const PxControllerDesc &)|
|copy constructor. |
|PX_INLINE PxControllerDesc &||operator= (const PxControllerDesc &)|
|assignment operator. |
|PX_INLINE void||copy (const PxControllerDesc &)|
|The type of the controller. This gets set by the derived class' ctor, the user should not have to change it. |
|PX_INLINE PxControllerShapeType::Enum PxControllerDesc::getType||(||)|| const
The contact offset used by the controller.
Specifies a skin around the object within which contacts will be generated. Use it to avoid numerical precision issues.
This is dependant on the scale of the users world, but should be a small, positive non zero value.
Height of invisible walls created around non-walkable triangles.
The library can automatically create invisible walls around non-walkable triangles defined by the 'slopeLimit' parameter. This defines the height of those walls. If it is 0.0, then no extra triangles are created.
Maximum height a jumping character can reach.
This is only used if invisible walls are created ('invisibleWallHeight' is non zero).
When a character jumps, the non-walkable triangles he might fly over are not found by the collision queries (since the character's bounding volume does not touch them). Thus those non-walkable triangles do not create invisible walls, and it is possible for a jumping character to land on a non-walkable triangle, while he wouldn't have reached that place by just walking.
The 'maxJumpHeight' variable is used to extend the size of the collision volume downward. This way, all the non-walkable triangles are properly found by the collision queries and it becomes impossible to 'jump over' invisible walls.
If the character in your game can not jump, it is safe to use 0.0 here. Otherwise it is best to keep this value as small as possible, since a larger collision volume means more triangles to process.
The type of the controller. This gets set by the derived class' ctor, the user should not have to change it.
Referenced by isValid().
Use a deletion listener to get informed about released objects and clear internal caches if needed.
If a character controller registers a deletion listener, it will get informed about released objects. That allows the controller to invalidate cached data that connects to a released object. If a deletion listener is not registered, PxController::invalidateCache has to be called manually after objects have been released.
The maximum slope which the character can walk up.
In general it is desirable to limit where the character can walk, in particular it is unrealistic for the character to be able to climb arbitary slopes.
The limit is expressed as the cosine of desired limit angle. A value of 0 disables this feature.
Defines the maximum height of an obstacle which the character can climb.
A small value will mean that the character gets stuck and cannot walk up stairs etc, a value which is too large will mean that the character can climb over unrealistically high obstacles.