Arma Reforger Script API
Loading...
Searching...
No Matches
BaseAnimPhysComponent Interface Reference
Inheritance diagram for BaseAnimPhysComponent:
GameComponent AnimalAnimationComponent CharacterAnimationComponent SCR_CharacterAnimationComponent

Public Member Functions

proto external void SetCurrentCommand (AnimPhysCommandScripted pCommand)
 
proto external AnimPhysCommandScripted GetCommandScripted ()
 
proto external TAnimGraphCommand BindCommand (string pCommandName)
 
proto external TAnimGraphVariable BindVariableFloat (string pVariableName)
 binds variable
 
proto external TAnimGraphVariable BindVariableInt (string pVariableName)
 
proto external TAnimGraphVariable BindVariableBool (string pVariableName)
 
proto external TAnimGraphTag BindTag (string pTagName)
 binds tag
 
proto external TAnimGraphEvent BindEvent (string pEventName)
 binds event
 
proto external TAnimGraphPrediction BindPrediction (string pPredictionName)
 binds prediction
 
proto external void SetVariableFloat (TAnimGraphVariable varIdx, float value)
 Functions for setting animation variables and calling animation commands.
 
proto external void SetVariableInt (TAnimGraphVariable varIdx, int value)
 
proto external void SetVariableBool (TAnimGraphVariable varIdx, bool value)
 
proto external void CallCommand (TAnimGraphCommand pCmdIndex, int intParam, float floatParam)
 
proto external void CallCommand4I (TAnimGraphCommand pCmdIndex, int intParam1, int intParam2, int intParam3, int intParam4, float floatParam)
 
proto external bool PhysicsIsFalling ()
 returns true when character is physically falling
 
proto external void PhysicsEnableGravity (bool pState)
 enables physics
 
proto external void PhysicsSetStance (int index)
 
proto external void PhysicsSetCollisionOffset (vector pOff)
 
proto external void PhysicsGetTransformWS (out vector mat[4])
 Returns physical transform in world space.
 
proto external void PhysicsGetTransformLS (out vector mat[4])
 Returns physical transform in local space of parent or linked entity.
 
proto external void PhysicsGetParentTransform (out vector mat[4])
 Returns physical transform of parent or linked entity.
 
proto external bool PhysicsIsLinked ()
 Returns true if the character is physically linked to another entity.
 
proto external IEntity GetLinkedEntity ()
 Returns linked entity if its found, null if its not found.
 
proto external vector PhysicsGetLocalVelocity ()
 Returns velocity in local space of parent or linked entity.
 
proto external vector PhysicsGetLocalVelocityXZ ()
 Same as method above, y coordinate is zero.
 
proto external vector PhysicsGetLocalYawPitchRoll ()
 Returns (yaw pitch roll) vector in local space of parent or linked entity In degrees.
 
- Public Member Functions inherited from GameComponent
bool OnTicksOnRemoteProxy ()
 

Member Function Documentation

◆ BindCommand()

proto external TAnimGraphCommand BaseAnimPhysComponent.BindCommand ( string pCommandName)

script binding

◆ BindEvent()

proto external TAnimGraphEvent BaseAnimPhysComponent.BindEvent ( string pEventName)

binds event

◆ BindPrediction()

proto external TAnimGraphPrediction BaseAnimPhysComponent.BindPrediction ( string pPredictionName)

binds prediction

◆ BindTag()

proto external TAnimGraphTag BaseAnimPhysComponent.BindTag ( string pTagName)

binds tag

◆ BindVariableBool()

proto external TAnimGraphVariable BaseAnimPhysComponent.BindVariableBool ( string pVariableName)

◆ BindVariableFloat()

proto external TAnimGraphVariable BaseAnimPhysComponent.BindVariableFloat ( string pVariableName)

binds variable

◆ BindVariableInt()

proto external TAnimGraphVariable BaseAnimPhysComponent.BindVariableInt ( string pVariableName)

◆ CallCommand()

proto external void BaseAnimPhysComponent.CallCommand ( TAnimGraphCommand pCmdIndex,
int intParam,
float floatParam )

◆ CallCommand4I()

proto external void BaseAnimPhysComponent.CallCommand4I ( TAnimGraphCommand pCmdIndex,
int intParam1,
int intParam2,
int intParam3,
int intParam4,
float floatParam )

◆ GetCommandScripted()

proto external AnimPhysCommandScripted BaseAnimPhysComponent.GetCommandScripted ( )

◆ GetLinkedEntity()

proto external IEntity BaseAnimPhysComponent.GetLinkedEntity ( )

Returns linked entity if its found, null if its not found.

If this returns a null, it doesn't mean we are not linked, so this shouldn't be used as a check if its linked

◆ PhysicsEnableGravity()

proto external void BaseAnimPhysComponent.PhysicsEnableGravity ( bool pState)

enables physics

◆ PhysicsGetLocalVelocity()

proto external vector BaseAnimPhysComponent.PhysicsGetLocalVelocity ( )

Returns velocity in local space of parent or linked entity.

Returned velocity is relative to the velocity of parent or linked enitity.

◆ PhysicsGetLocalVelocityXZ()

proto external vector BaseAnimPhysComponent.PhysicsGetLocalVelocityXZ ( )

Same as method above, y coordinate is zero.

◆ PhysicsGetLocalYawPitchRoll()

proto external vector BaseAnimPhysComponent.PhysicsGetLocalYawPitchRoll ( )

Returns (yaw pitch roll) vector in local space of parent or linked entity In degrees.

◆ PhysicsGetParentTransform()

proto external void BaseAnimPhysComponent.PhysicsGetParentTransform ( out vector mat[4])

Returns physical transform of parent or linked entity.

◆ PhysicsGetTransformLS()

proto external void BaseAnimPhysComponent.PhysicsGetTransformLS ( out vector mat[4])

Returns physical transform in local space of parent or linked entity.

◆ PhysicsGetTransformWS()

proto external void BaseAnimPhysComponent.PhysicsGetTransformWS ( out vector mat[4])

Returns physical transform in world space.


physics transform API

This new transform API is needed for physically linking with another entity. Linking with another entity means that we are making the another entity our parent, but not in entity hierarchy terms, only in physical terms. The physical movement and transform will work as if the linked entity would be parent in entity hierarchy, but we have more control and don't have the overhead of entity hierarchy. If there is a linked entity, it doesn't mean that owner has a parent in entity hierarchy. All of the methods of this physics transform api were done to work even if the linked entity is not streamed in or is deleted. If the entity is not found, but we are still linked, we use the last known linked entity transformation to prevent distrupting transform changes when streaming in/out. Physical parent transform doesn't have to be the same as the parent's or linked entity transform. We do that to prevent quick character orientation change when linking to an entity. It does make linking transition much simpler for systems that use owner's local transformation. This API should be used if you care about LS of the owner when its linked. If you only care about world transform of the owner, you can use owner's entity API. Use cases of this API should be camera, commands or theoretically any code that works with position/orientation of owner and needs to work in the space of the linked entity.

◆ PhysicsIsFalling()

proto external bool BaseAnimPhysComponent.PhysicsIsFalling ( )

returns true when character is physically falling

◆ PhysicsIsLinked()

proto external bool BaseAnimPhysComponent.PhysicsIsLinked ( )

Returns true if the character is physically linked to another entity.

◆ PhysicsSetCollisionOffset()

proto external void BaseAnimPhysComponent.PhysicsSetCollisionOffset ( vector pOff)

◆ PhysicsSetStance()

proto external void BaseAnimPhysComponent.PhysicsSetStance ( int index)

◆ SetCurrentCommand()

proto external void BaseAnimPhysComponent.SetCurrentCommand ( AnimPhysCommandScripted pCommand)

commands

◆ SetVariableBool()

proto external void BaseAnimPhysComponent.SetVariableBool ( TAnimGraphVariable varIdx,
bool value )

◆ SetVariableFloat()

proto external void BaseAnimPhysComponent.SetVariableFloat ( TAnimGraphVariable varIdx,
float value )

Functions for setting animation variables and calling animation commands.

It is recommended to, instead of binding and setting the variables directly, use a ScriptedCommand object with a static table, and to set those variables in the PreAnimUpdate function using the functions provideed by ScriptedCommand instead. For an example on how to use those, see SCR_CharacterCommandSwim. Animation variables can also be overwritten by the character commands, as they are evaluated right before animations, leading to manually set values being discarded.

◆ SetVariableInt()

proto external void BaseAnimPhysComponent.SetVariableInt ( TAnimGraphVariable varIdx,
int value )

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