API ReferenceGE Extensionsflowgraphnodesinput
Set Input Actions (Flowgraph Node)
- **Node Name:** `Set Input Actions`
Overview
- Node Name:
Set Input Actions - Category:
once_instant - File:
extensions/flowgraph/nodes/input/blacklistAction.lua - Tags: blacklist, whitelist, allow, deny, block, unblock, disallow, command, control
Enables or disables various input actions (like vehicle switching, recovery, etc.) similar to how scenarios restrict player actions.
Pin Schema
Input Pins
| Pin | Type | Default | Description |
|---|---|---|---|
block | bool | true | If true, block actions; if false, unblock (hidden, hardcoded) |
ignoreUnrestriced | bool | true | Ignore if competitive scenario conditions are disabled (hidden, hardcoded) |
id | number | - | Optional: ID of a specific action set to modify (hidden) |
Output Pins
| Pin | Type | Description |
|---|---|---|
id | number | ID of the registered action set (hidden) |
Presets
- Empty - No actions
- Scenario - Default scenario actions:
switch_next_vehicle,switch_previous_vehicle,loadHome,saveHome,recover_vehicle,reload_vehicle,reload_all_vehicles,vehicle_selector,parts_selector,dropPlayerAtCamera,nodegrabberRender,slower_motion,faster_motion,toggle_slow_motion,toggleWalkingMode,toggleCamera,toggleTraffic,toggleAITraffic
Internals
- Maintains a
self.listof action names (serialized with the node). - Has a full editor UI with search, category browsing, presets, and per-action checkboxes.
- Registers the action list with
mgr.modules.action:registerList()and gets back an ID. - Calls
mgr.modules.action:blockActions(id)orallowActions(id)based on theblockpin. - If
ignoreUnrestricedis true andrestrictScenariossetting is disabled, uses an empty list. - The
drawMiddle()method shows the action count and block/allow icon.
How It Works
- On execution, registers the configured action list with the flowgraph action module.
- Blocks or allows the registered actions based on the
blockpin value. - The ID output allows other nodes to reference and modify the same action set.
- Respects the game's
restrictScenariossetting whenignoreUnrestricedis enabled.
Lua Code Example
-- Block specific actions via the action filter system
core_input_actionFilter.addAction(0, "switch_next_vehicle", false)
core_input_actionFilter.addAction(0, "recover_vehicle", false)Key Dependencies
core_input_actionFilter- action filtering systemcore_input_actions.getActiveActions()- retrieves all available input actions- Flowgraph
actionmodule - manages action block/allow lists
Additional Methods
C:_onDeserialized(data)
Called after the node is deserialized (loaded from file). Restores runtime state from saved data.
Parameters:
data
C:_onSerialize(res)
Called when the node is serialized (saved to file). Returns data to persist.
Parameters:
res
C:drawCustomProperties()
Custom ImGui drawing for the node's properties panel in the editor.
C:drawSearchInput()
Custom ImGui drawing function for the node editor.
C:highlightText(label, highlightText)
Node method.
Parameters:
labelhighlightText
C:init()
Initializes the node, setting up pins and default properties.
C:workOnce()
Called once when the node is triggered (flow-once execution).
See Also
- Set Input Action Filters (Flowgraph Node) - Related reference
- Get Action Control (Flowgraph Node) - Related reference
- FlowGraph Guide - Guide