Basiccharactercontroller

BasicCharacterController class

A controller class that can be used to control kinematic rigid bodies. This is a convenient class that wraps the Rapier's Character controller (opens in a new tab) class.

Signature:

export declare class BasicCharacterController 

Constructors

Constructor

Modifiers

Description

(constructor)(opts)

Constructs a new instance of the BasicCharacterController class

Properties

Property

Modifiers

Type

Description

_firstFrame

boolean

accumulator

number

controlVelocity

Vector3

dampling

number

forces

any[]

gravity

Vector3

onFloor

boolean

previousVelocity

Vector3

rotation

Euler

velocity

Vector3

Methods

Method

Modifiers

Description

_updateCollisionState(collider, playerCollider, collision)

_updateIntersectionState(collider, playerCollider)

castCallback(collider, now, collision, delta, playerCollider)

castSensors(rigidbody, rpos, collider)

getCCState(object)

update(object, velocity, dt)