Dear list,

Below is another experiment in animating from the seq function. I made a
"temp-cube" which should be a temporary cube. The first time it's called it
works fine as you'll see; the cube disappears after a second. From there on
(seq ) proceeds to build a nice wall of non-disappearing cubes, while I was
expecting those to disappear after a while as well. Something seems wrong
here.

Yours,
Kas.

(clear)
(define (temp-cube end)
    (let ((x (build-cube)))
        (spawn-timed-task
            (+ (time-now) end)
            (λ () (destroy x)))
        x))

(temp-cube 1)

(seq (λ (time clock)
    (spawn-timed-task
        time
        (λ ()
            (with-state
                (hint-none)
                (hint-wire)
                (wire-colour (vnormalise (rndvec)))
                (translate (vector (modulo clock 16) (modulo clock 7)
(modulo clock 5)))
                (temp-cube 1))))
    .2))

Reply via email to