GameFeatureActions

CrimsonCore provides a full set of UGameFeatureAction subclasses that compose any feature into an experience via data assets. All GFAs are reversible — they undo their changes when the experience deactivates or the feature plugin is unloaded.

GFA classWhat it does
UGFA_AddAbilitiesGrants UCrimsonAbilitySets (abilities + attribute sets + effects) to actors matching a class filter. Revokes on deactivate.
UGFA_AddInputBindingRegisters UCrimsonInputConfigs with UCrimsonHeroComponent on each player pawn. Removes bindings on deactivate.
UGFA_AddWidgetPushes HUD layouts and registers widget extensions via UIExtensionSubsystem. Removes them on deactivate.
UGFA_AddTeamsAttaches UCrimsonTeamAgentComponent and populates team / hostile tags. Tears down on deactivate.
UGFA_AddInventoryAttaches UCrimsonInventoryManagerComponent with constraint and currency tables.
UGFA_AddEquipmentSlotsAttaches UCrimsonEquipmentSlotsComponent and UCrimsonEquipmentManagerComponent with a configured slot layout.
UGFA_AddHotbarAttaches UCrimsonHotbarContainerComponent and per-hotbar manager components.
UGFA_AddNPCSpawnerPrimes UCrimsonEnemySpawnerSubsystem before spawner actors tick.
UGFA_AddSummonsEnables summon ability support for the experience.
UGFA_AddCompanionsEnables companion roster on the PlayerState.
UGFA_AddContainerInstancesRegisters UCrimsonContainerData payloads at a HUD extension slot.
UGFA_SetupCameraPer-feature camera setup: assigns a UCrimsonLockOnConfig to the pawn's lock-on component (adds it if missing), optionally adds a lockable target component, and optionally overrides the pawn's default camera mode. Composes with existing components and restores all on deactivate.
UGFA_SplitscreenConfigReference-counted vote to disable splitscreen for the active world.
UCrimsonGameFeatureAction_AddGameplayCuePathRegisters gameplay cue notify paths with UAbilitySystemGlobals when the feature registers (not just when it activates).

Typical ExperienceDefinition setup

text
DA_Experience_Dungeon
DefaultPawnData = DA_PawnData_Fighter
GameFeaturesToEnable = ["DungeonFeature"]
Actions:
[0] UGFA_AddAbilities
AbilitiesList[0].ActorClass = BP_CrimsonCharacter
AbilitiesList[0].GrantedAbilitySets = [DA_AbilitySet_Fighter]
[1] UGFA_AddInputBinding
InputConfigs[0].ActorClass = BP_CrimsonCharacter
InputConfigs[0].InputConfig = DA_InputConfig_Fighter
[2] UGFA_AddWidget
Widgets[0].LayerTag = UI.Layer.Game
Widgets[0].WidgetClass = WBP_HUD_Dungeon
[3] UGFA_AddTeams
TeamsToAdd = [TAG_Team_Player, TAG_Team_Enemy]