If
Runs on: Shared. Runs on the Community backend or inside a chatbox overlay.
The most flexible comparison check. Its operations adapt to the type of A: strings get equality, inequality, contains, starts-with and ends-with; numbers get equality and relational operators; booleans get equality and inequality. When A is an object, pick a field to compare instead of the whole thing.
B can be wired to an input or entered inline on the node. When the comparison is true the original A goes down Pass, otherwise down Fail.
Inputs
| Name | Type | Description |
|---|---|---|
a | any | The value to compare. Passed through on whichever output fires. |
b | any | The value to compare against. When not connected, enter it inline on the node. |
Outputs
| Name | Type | Description |
|---|---|---|
pass | pass-through | The original A, when the comparison is true. |
fail | pass-through | The original A, when it's false. |
Configuration
- Operation: Depends on the type of A:
=,≠,contains,starts,endsfor strings;=,≠,>,<,≥,≤for numbers;=,≠for booleans. - Inline B value: The comparison value, used when B isn't connected.
- Field path (objects only): Which field of A to compare.
- Case sensitive (strings only): Makes string comparisons case-sensitive.
Example
After a Channel Cheer trigger, connect the bits amount to A, set the inline B value to 1000 and the operator to ≥. Cheers of 1000 bits or more take Pass to a VIP alert and thank-you TTS. Smaller cheers take Fail to a standard acknowledgment.