diff options
-rw-r--r-- | sly/live-reload.scm | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/sly/live-reload.scm b/sly/live-reload.scm index cb40e7c..bb828e8 100644 --- a/sly/live-reload.scm +++ b/sly/live-reload.scm @@ -25,6 +25,7 @@ #:use-module (srfi srfi-1) #:use-module (sly agenda) #:use-module (sly coroutine) + #:use-module (sly game) #:use-module (sly signal) #:export (watch-files with-live-reload)) @@ -48,6 +49,8 @@ polled for changes, defaulting to two seconds." (wait polling-interval) (let ((mtime (max-current-mtime))) (when (cond + ;; Game hasn't started yet. + ((not (signal-ref game-started?)) #f) ;; Some files do not exist anymore, can't reload. ((not mtime) #f) ;; Some files were missing, but are back now. |