Menu
Lumberyard
Legacy Reference

Logic Nodes

Flow Graph is deprecated and will be removed in a future version of Lumberyard. Learn about Script Canvas, Lumberyard's new visual scripting environment.

This topic references tools and features that are legacy. If you want to use legacy tools in Lumberyard Editor, disable the CryEntity Removal gem using the Project Configurator or the command line. To learn about the latest features, see the Amazon Lumberyard User Guide.

You can use the following flow graph nodes to define logic operations.

AND node

Used to perform a logical AND operation on the input ports. Output is true if both inputs are true.

Inputs

Port Type Description
Activate Any Triggers the node
A Boolean First input
B Boolean Second input

Outputs

Port Type Description
Out Boolean Output value
OnTrue Boolean Triggers if Out is true
OnFalse Boolean Triggers if Out is false

All node

Used to trigger the output when all connected inputs are triggered.

Inputs

Port Type Description
In0 - In7 Any Input values
Reset Any Resets the input values to 0

Outputs

Port Type Description
Out Any Triggered when all inputs are triggered

Any node

Used to trigger the output when any of the connected inputs are triggered.

Inputs

Port Type Description
In0 - In9 Any Input values

Outputs

Port Type Description
Out Any Triggered when any inputs are triggered

Blocker node

Used to block or pass signals depending on the state of the Block input.

Inputs

Port Type Description
Block Boolean If true, blocks In signal
In Any Input signal

Outputs

Port Type Description
Out Any If Block is false, outputs In signal. If Block is true, In signal is blocked.

CountBlocker node

Used to output a signal a number of times as defined by the Limit input.

Inputs

Port Type Description
In Any Input value
Reset Any Resets In to 0
Limit Integer Number of times In is sent to Out

Outputs

Port Type Description
Out Any Passes In a limited number of times as defined by Limit

DeMultiplexer node

Used to send the In input to the selected Out output, based on the value of the Mode input:

  • Always: Both the In and Index inputs activate the output.

  • IndexOnly: Only the Index input activates the output.

  • InputOnly: Only the In port activates the output.

Inputs

Port Type Description
Index Integer Determines which output receives the input (In)
Mode Integer Determines when the outputs are activated
In Any Input value

Outputs

Port Type Description
Out0 - Out7 Any Outputs that can be triggered

Gate node

Used to block or pass a signal depending on the state of the Closed input.

Inputs

Port Type Description
In Any Input value
Closed Boolean If true, blocks the input from passing to the output
Open Any Sets Closed to false
Close Any Sets Closed to true

Outputs

Port Type Description
Out Any Output value
OutClosed Any Output if Closed is true

IfCondition node

Used to output signals based on whether the Condition input is enabled.

Inputs

Port Type Description
Activate Any Triggers the node
Condition Boolean Condition value
In Any Input value

Outputs

Port Type Description
OnFalse Any Triggers if Condition is false
OnTrue Any Triggers if Condition is true

Indexer node

Used to return the index of an active input. Does not account for multiple activations on different inputs.

Inputs

Port Type Description
In0 - In7 Any Input values

Outputs

Port Type Description
OutIndex Integer Outputs the index (number) of the active input

Multiplexer node

Used to select an input and send it to the output, based on the value of the Mode input:

  • Always: Both the In and Index inputs activate the output.

  • IndexOnly: Only the Index input activates the output.

  • InputOnly: Only the In port activates the output.

Inputs

Port Type Description
Index Integer Determines which input is passed to the output
Mode Integer Determineswhich inputs activate the output
In0 - In7 Any Input values

Outputs

Port Type Description
Output Any Output value

NOT node

Used to perform a logical NOT operation on the input ports. If the input is true, the output will be false and vice versa.

Inputs

Port Type Description
In Boolean Input value

Outputs

Port Type Description
Out Boolean If the input is true, the output will be false and vice versa

OR node

Used to perform a logical OR operation on the input ports. The output is true if either of the two inputs is true.

Inputs

Port Type Description
Activate Any Triggers the node
A Boolean First input
B Boolean Second input

Outputs

Port Type Description
Out Boolean Output is true if either of the two inputs is true
OnTrue Boolean Triggers if Out is true
OnFalse Boolean Triggers if Out is false

OnChange node

Used to send the input value to the output when it is different from the previous value.

Inputs

Port Type Description
In Boolean Input value

Outputs

Port Type Description
Out Boolean Receives the input value when the input has changed from it's previous value

Once node

Used to pass the activated input to the output only once.

Inputs

Port Type Description
In0 - In7 Any Input values
Reset Any Resets the inputs and allows new activation to occur

Outputs

Port Type Description
Out Any Receives the active input only once

OnceNoSerialize node

Use to pass the activated input value to the output only once. The triggered flag is not serialized on a saved game. This means that even if a previous savegame is loaded after the node has been triggered, the node won't be triggered again.

Inputs

Port Type Description
In Any Input value
Reset Any Resets the input and allows new activation to occur

Outputs

Port Type Description
Out Any Receives the active input only once

RandomSelect node

Used to pass the activated input value to a random number of outputs.

Inputs

Port Type Description
In Any Input value
MinOut Integer Minimum number of outputs to trigger
MaxOut Integer Maximum number of outputs to trigger

Outputs

Port Type Description
Out0 - Out9 Any Receives active input values

RandomTrigger node

Used to trigger one of the outputs in random order.

Inputs

Port Type Description
In Any Input value
Reset Any Resets the activations to 0

Outputs

Port Type Description
Out0 - Out9 Any Output value
Done Any Triggered when all outputs have been triggered

SelectCondition node

Used to trigger the output based on the state of the Condition node.

Inputs

Port Type Description
Activate Any Triggers the node
Condition Boolean Condition value
InTrue Any Value sent to Out when Condition is true
InFalse Any Value sent to Out when Condition is false

Outputs

Port Type Description
Out Any Output value

Sequencer node

Used to trigger one of the outputs in sequential order for each input activation.

Inputs

Port Type Description
In Any Input value
Closed Boolean If true, blocks all inputs
Open Any Sets Closed to false
Close Any Sets Closed to true
Reset Any Forces active output to Out0
Reverse Boolean If true, the order of output activation is reversed

Outputs

Port Type Description
Out0 - Out9 Any Outputs are triggered in sequential order for each input activation

XOR node

Used to perform a logical XOR operation on the input ports. If one of the inputs is true, the output is true. If both inputs are true or are false, the output is false.

Inputs

Port Type Description
Activate Any Triggers the node
A Boolean First input
B Boolean Second input

Outputs

Port Type Description
Out Boolean If one of the inputs is true, the output is true. If both inputs are true or are false, the output is false
OnTrue Boolean Triggers if Out is true
OnFalse Boolean Triggers if Out is false