SLEEP
Description
SLEEP is a behavior command that makes the robot wait a time value in seconds before executing the next SaviScript command.
note
If a DISPLAY command is not used in conjunction with SLEEP, the on-screen message will immediately expire!
Syntax
DISPLAY "First message"
SLEEP value
DISPLAY "Second message"
Arguments
value: time in seconds
Example
Input
DISPLAY "Hello, now it's time t=0"
SLEEP 5
DISPLAY "Hello, now it's time t + 5 seconds"
SLEEP 5
Output
Screen will display "Hello, now it's time t=0". Then, the robot will pause for five seconds, maintaining the display message. Then, the screen will display "Hello, now it's time t + 5 seconds". Finally, the robot will pause for another 5 seconds, holding the second message, and the program will end.
Resources
Explore the SaviScript GitHub repository for all published instances of this command.