DO([count])
- Category
- Control Flow
- Added in
- v0.6
Begins a loop. Needs to be closed with LOOP,
WHILE
, or UNTIL
.
The loop can be exited early by using BREAK
.
It is possible to specify a [count]
number for it to have a maximum amount of loops. If this number is not specified, it will loop indefinitely.
Example
log("start");
do(5);
log("looping over");
loop;
log("end");
Actions
Name
Description
UNTIL(<condition>)
Completes a loop started with DO but exits the loop if <condition>
is met
WHILE(<condition>)
Completes a loop started with DO but exits the loop if <condition>
is not met
LOOP
Ends a loop that was started with DO
BREAK
Interrupts exection of the innermost loop