Action Context Setup – Arma Reforger

From Bohemia Interactive Community
Revision as of 16:18, 20 May 2022 by Lou Montana (talk | contribs) (Page creation)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

Select Entity

Select the entity you want to add contexts and actions into. Select the "ActionsManagerComponent" or add one if it doesn't exist.

  • For user actions to be properly synchronized and work as intended, the entity requires a RplComponent.
  • ActionsManagerComponent is not the same thing as ActionManager. The former manages user actions, the latter input actions!
  • To be able to interact with the entity properly, such entity must have valid physical representation. For most entities, this is already the case. If you are setting up an entity from scratch, please make sure that:
    • Entity has MeshObject component with valid mesh
    • Entity has RigidBody component with Model Geometry checked.

armareforger-actioncontext add component.png


Define Context

Fill the ActionContexts array with your contexts for this entity. The context name is a unique identifier used to register child actions. Do not forget to fill the Position field with valid PointInfo or derived class instance.

armareforger-actioncontext add context.png


Add Action Location

General Action

For general actions use the additionalActions field in the ActionsManagerComponent.

armareforger-actioncontext add action general.png

Contextual Action

For actions provided by a component (compartments - GetInAction, doors - DoorAction) find the proper component. In this case it will be one of this entity's DoorComponent.

armareforger-actioncontext add action component.png


Add Action

General Action

For general actions add the action straight into the "additionalActions" field in the ActionsManagerComponent. To set a parent context for our new action add an entry to the "ParentContextList" field of the action. As the value choose one of the context names you specified in the "ActionContexts" field in the "ActionsManagerComponent". Don't forget to add UIInfo and fill it with desired data. If an action should be visible in multiple contexts, add that unique identifier (target context's ContextName) to the "ParentContextList" too.

armareforger-actioncontext setup action general.png

Contextual Action

For actions provided by a component add the action to a slot provided by the component. In this case the field "DoorAction" provided by the "DoorComponent". To set a parent context for our new action add an entry to the "ParentContextList" field of the action. As the value choose one of the context names you specified in the "ActionContexts" field in the "ActionsManagerComponent". Don't forget to add UIInfo and fill it with desired data. If an action should be visible in multiple contexts, add that unique identifier (target context's ContextName) to the "ParentContextList" too.

armareforger-actioncontext setup action component.png