Augment System

Augments (UCrimsonAbilityAugment) are data assets that modify abilities - think runes or gems. Each one mutates an ability's stats, attributes, classes, objects, tags, or behavior through slots the ability's contract declares, with zero code changes to the ability.

Compatibility & slotting

FieldPurpose
TargetModeSpecificContract -> binds to one TargetContract; ContractFamily -> matches TargetFamilyQuery against contract IdentityTags
SlotCategoryThe contract slot this augment occupies (the contract must declare it)
SlotCostSlot capacity consumed (>= 1)
RequiresAugmentTagsEquippable only if a co-equipped augment carries one of these tags
ConflictsAugmentTagsRejected if a co-equipped augment carries one of these tags

Mutation types

Mutation arrayWhat it modifiesExample
StatMutationsContract properties by tag (Additive / Multiplicative / Override, MinimumLevel)+1 projectile, -0.5s cooldown
AttributeMutationsAttributes baked into GE specs+15% crit chance, +10 attack power
ClassMutationsSwaps a contract class slot by tagReplace default projectile with ice
ObjectMutationsSwaps a contract object slot by tagReplace fire SFX with ice
TagMutationsAdd / Remove / Replace tags on the ability specAdd Ability.Fire to a physical ability

Augment actions

UCrimsonAugmentAction objects are instanced in the augment's Actions array. Each fires when its ExecutionEventTag matches a broadcast event. Built-in actions:

ActionPurpose
ApplyGameplayEffectApplies a GE to caster or targets with optional scaling
ModifySetByCallerModifies a SetByCaller magnitude in the in-flight GE spec
ModifySpecAttributeApplies an attribute mutation to an in-flight spec
ModifyContextModifies FCrimsonAugmentActionContext for downstream actions
SpawnActorSpawns an actor at the hit location
FindTargetsOverlap sweep; injects results into TargetData
GrantAndActivateAbilityGrants and immediately activates a secondary ability
ReduceCooldownReduces a cooldown by tag on the owning ASC
ConsumeEffectStacksConsumes GE stacks by tag; results via context
ChanceGates child actions behind a probability
ConditionalGates child actions behind a context tag condition

Custom actions: subclass UCrimsonAugmentAction, override Execute_Implementation, add to the augment's Actions array.

Stateful listeners

For behaviors needing persistent state across events (e.g. count 5 hits then proc), add UCrimsonStatefulAugmentBase subclasses to StatefulListeners. Built-in:

ClassBehavior
HitCounterAccumulates hit events, fires after N hits
EventTriggerReacts to a specific event tag and fires its actions
ApplyGameplayEffectApplies a GE persistently while active
ReplaceAbilityTemporarily replaces the owning ability
ModifyTagsAdds/removes tags on the ability spec while active
StackConsumerConsumes GE stacks per event and scales output
Equipping at runtime
See How-To: Create & Equip an Augment for the slot-based equip API (TryEquipAugmentToSlot, EquipAugmentToFirstFreeSlot, temp slots) and the ECrimsonEquipFailure reasons.