🧩 Pickups System — Pickup Execution Flow¶
What it’s showing¶
This diagram shows the main execution path from authored pickup data to runtime effect application.
flowchart TD
A[Definition<br/>PickupEffectDefinitionBase]
B[Factory<br/>PickupEffectFactory]
C[Effect Chain<br/>PickupEffect + Decorators]
D[Runtime Pickup<br/>TriggerPickup / InteractablePickupBase]
E[Runner<br/>PickupEffectRunner]
F[Actor]
A --> B
B --> C
F --> D
D --> E
E --> C
Reading the flow¶
1. Definition¶
A pickup starts as authored data.
This is usually a PickupEffectDefinitionBase asset that describes:
- what effect to build
- what decorator data to include
2. Factory¶
PickupEffectFactory turns that definition into a runtime effect chain.
That means:
- create the core
PickupEffect - wrap decorators around it if configured
3. Effect Chain¶
The result is a single executable effect chain.
That chain may contain:
- one core effect
- zero or more decorators
At runtime, this behaves as one payload.
4. Runtime Pickup¶
TriggerPickup or InteractablePickupBase decides when the pickup should attempt to apply that effect.
This layer handles things like:
- trigger/contact flow
- input/hold flow
- optional authority checks
- pickup lifecycle
5. Runner¶
PickupEffectRunner applies the effect chain using the correct entry path.
This is where standard effects and context-aware effects are dispatched correctly.
6. Actor¶
The actor is the thing trying to consume the pickup.
It provides the runtime target/context for the effect application.
Mental shortcut¶
Think of Pickups like this:
Definition = authored data
Factory = builds runtime payload
Effect Chain = gameplay behaviour
Runtime Pickup = delivery rule
Runner = applies it
Actor = receives it
Key idea¶
The pickup does not define the gameplay payload.
The pickup only decides:
“Should this effect be delivered now?”
The effect chain decides:
“What actually happens?”
Why this matters¶
This split is what keeps the system clean:
- change gameplay behaviour → effect
- change wrapping behaviour → decorator
- change authoring → definition
- change consume rules → runtime pickup
Blunt recommendation¶
Use this version or remove the page.
This one teaches something.