Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 13 additions & 0 deletions streamerbot/3.api/1.sub-actions/core/logic/switch.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,3 +20,16 @@ parameters:
- `0`{lang=cs} can be auto-typed to a numeric type such as `int`{lang=cs} or `long`{lang=cs}
- `true`{lang=cs} or `false`{lang=cs} can be auto-typed to a `bool`{lang=cs}
---

You can add any number of cases to a switch by right clicking on the `switch` Sub-Action and selecting "Add Case"

![Switch Sub-Action context menu showing "Add Case" option](assets/switch-add-case-context-menu.png)

You can add one or more values to a case. If any of the case's values match the `switch` input, that case will be executed.

![Add Case Dialogue](assets/switch-add-case-dialogue.png)

::note
Only the first matching case will be executed.
- If no cases match, the `default` case will be executed.
::
Loading