19. Put game logic in Action nodes
An Action node runs one action from PCA’s shared catalog, then follows its flow rule. You can use the same kinds of actions that appear in action lists and visual scripts.
Figure 15. This Action changes a Boolean story variable before the next spoken reply.
| You want to… | Action |
|---|---|
| Record a story change | Set Variable. |
| Give the active player an item | Add Inventory. |
| Give a specific character an item | Give Inventory. |
| Remove a carried item | Remove Inventory. |
| Run project code | Run Script, or Call Script Function for exposed functions. |
| Start another conversation | Start Dialogue. |
| Play a cinematic | Start Cutscene. |
| Change a camera or animation | The relevant camera or animation action. |
Choose Type first, then fill in the fields it displays. Changing Type replaces the old action configuration with defaults for the new type. Review every field after switching types.
An Action node is one step. To perform several steps in order, connect several Action nodes, or call a script/action list that owns the sequence.
