summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDavid Thompson <dthompson@vistahigherlearning.com>2017-10-27 12:07:09 -0400
committerDavid Thompson <dthompson@vistahigherlearning.com>2017-10-27 12:07:09 -0400
commit6eccb1070de640e6bfdef46ba4c4d96cfaa375b8 (patch)
treef709706773c3f1040d50d79a212212a96148c99a
parenta4df9bffb24b84322b139d1934991d3ce8e2c1f9 (diff)
doc: scripting: Replace references to "wait" with "sleep".
-rw-r--r--doc/api.texi8
1 files changed, 4 insertions, 4 deletions
diff --git a/doc/api.texi b/doc/api.texi
index 022c103..cb3c885 100644
--- a/doc/api.texi
+++ b/doc/api.texi
@@ -1271,10 +1271,10 @@ trying to get their mother's attention:
(while #t
(display "mom!")
(newline)
- (wait 60))) ; where 60 = 1 second of real time
+ (sleep 60))) ; where 60 = 1 second of real time
@end example
-This code runs in an endless loop, but the @code{wait} procedure
+This code runs in an endless loop, but the @code{sleep} procedure
suspends the script and schedules it to be run later by the agenda.
So, after each iteration of the loop, control is returned back to the
game loop and the program is not stuck spinning in a loop that will
@@ -1294,7 +1294,7 @@ needs to be shut down. When a script is spawned, a handle to that
script is returned that can be used to cancel it when desired.
@example
-(define script (script (while #t (display "hey\n") (wait 60))))
+(define script (script (while #t (display "hey\n") (sleep 60))))
;; sometime later
(cancel-script script)
@end example
@@ -1333,7 +1333,7 @@ Suspend the current script and pass its continuation to the
procedure @var{handler}.
@end deffn
-@deffn {Procedure} wait @var{duration}
+@deffn {Procedure} sleep @var{duration}
Wait @var{duration} before resuming the current script.
@end deffn