API

Fields

Field

Description

Sprint

Action used for all components to know when the player is sprinting and when he is not.

Aim

Action used for all components to know when the player is aiming and when he is not.

Crouch

Action used for all components to know when the player is crouching and when he is not.

Shoot

Attempt triggered when the player tries to shoot by using the shootKey, (this event is used when subscribing to shoot).

ShootHold

Attempt triggered when the player tries to shoot continuosly (holding the button down) by using the shootKey.

ShootOnce

Attempt triggered when the player tries to shoot semi-automatically (clicking repeatedly) by using the shootKey.

Reload

Attempt triggered when the player tries to reload by using the reloadKey.

ChangeWeapon

Attempt triggered when the player tries to change weapons by using the changeWeaponKey.

GroundState

Value containing the controller's grounding state.

Velocity

Value containing the controller's velocity.

Persistent events are a special type of event that does not remove listeners when the game-object they were on is destroyed, or inactive.

Other fields

Property

Description

motionOnByDefault

Determines if procedural motions are enabled when the game starts.

sprintKey

Key used for the player to sprint.

crouchKey

Key used for the player to crouch.

shootKey

Key used for the player to shoot.

aimKey

Key used for the player to aim.

reloadKey

Key used for the player to reload.

changeWeaponKey

Key used for the player to change weapon.

turnOffAssetKey

Key used for the player to turn the asset's effects ON/OFF.

Last updated

Was this helpful?