This is an old revision of the document!
Table of Contents
CharacterControllerComponent
Provides functionality for wheeled vehicles.
class: CharacterControllerComponent
Parent Class: PrimaryControllerComponent
Location: scripts/Game/generated/Components/CharacterControllerComponent.c
—
Common usage
wip
Functions
Events
OnInit()
OnInit(IEntity owner);
Called during EOnInit. param owner Entity this component is attached to.
Return type: void
OnDiag()
OnDiag(IEntity owner, float timeslice);
Called during EOnDiag. Param owner Entity this component is attached to. param timeSlice Delta time since last update.
Return type: void
OnReloaded()
OnReloaded(IEntity owner, BaseWeaponComponent weapon);
Return type: void
OnPrepareControls()
OnPrepareControls(IEntity owner, ActionManager am, float dt, bool player);
Return type: void
OnApplyControls()
OnApplyControls(IEntity owner, float timeSlice);
Return type: void
OnMeleeDamage()
OnMeleeDamage(bool started);
Handling of melee events. Sends true if melee started, false, when melee ends
GetCanMeleeAttack()
GetCanMeleeAttack();
Return type: bool
OnPerformAction()
OnPerformAction();
Override to handle what happens after pressing F button, return false to use default cpp behavior
Return type: bool
CanGetOutVehicleScript()
CanGetOutVehicleScript();
Override to handle whether character can get out of vehicle via GetOut input action
Return type: bool
OnDeath()
OnGadgetStateChanged()
OnGadgetStateChanged(IEntity gadget, bool isInHand, bool isOnGround);
Will be called when gadget taken/removed from hand
Return type: void
OnGadgetFocusStateChanged()
OnGadgetFocusStateChanged(IEntity gadget, bool isFocused);
Will be called when gadget fully transitioned to or canceled focus mode
Return type: void
OnItemUseBegan()
OnItemUseComplete()
OnAnimationEvent()
OnAnimationEvent(AnimationEventID animEventType, AnimationEventID animUserString, int intParam, float timeFromStart, float timeToEnd);
Return type: void
OnControlledByPlayer()
OnControlledByPlayer(IEntity owner, bool controlled);
Called when a player has been assigned to this controller
Return type: void