fixed rate argument for run-movie, Closes PR13642
This commit is contained in:
parent
68f526c2ed
commit
1ff3e3b942
13
collects/2htdp/tests/run-movie.rkt
Normal file
13
collects/2htdp/tests/run-movie.rkt
Normal file
|
@ -0,0 +1,13 @@
|
|||
#lang racket
|
||||
|
||||
(require 2htdp/universe 2htdp/image)
|
||||
|
||||
(define (make-images i)
|
||||
(cond
|
||||
[(zero? i) '()]
|
||||
[else (cons (place-image DOT 50 (* 50 i) BACKGROUND) (make-images (sub1 i)))]))
|
||||
|
||||
(define DOT (circle 3 'solid 'red))
|
||||
(define BACKGROUND (empty-scene 100 400))
|
||||
|
||||
(run-movie 8 (make-images 8))
|
|
@ -327,7 +327,7 @@
|
|||
[hgt (image-height fst)])
|
||||
(big-bang
|
||||
m*
|
||||
(on-tick rest r)
|
||||
(on-tick rest (/ 1 r))
|
||||
(on-draw (lambda (m) (if (empty? m) (text "The End" 22 'red) (first m))))
|
||||
(stop-when empty?))))
|
||||
|
||||
|
|
|
@ -11,6 +11,7 @@ run() {
|
|||
cd tests
|
||||
|
||||
run key-error.rkt
|
||||
run run-movie.rkt
|
||||
run bad-draw.rkt
|
||||
run error-in-tick.rkt
|
||||
run error-in-draw.rkt
|
||||
|
|
Loading…
Reference in New Issue
Block a user