I've been meaning to post this for some time--now that I have a couple days 
free, here it is.

I've observed an interesting side effect of timeout objects. Here are two 
versions of the same piece. This one has a timeout object:
http://home.earthlink.net/~kerry_thompson/portfolio/lnlogo/logopiece.htm

and this one doesn't:
http://home.earthlink.net/~kerry_thompson/portfolio/lnlogo/logopiece_notime.htm

For reference, I'll call the big bouncing sprite the "floater," and the 
smaller sprites the "tethered sprites."

Look at the difference in movement. Without the timeout object, the 
tethered sprites lock onto the floater. With the timeout object, the 
tethered sprites lag a little behind the floater, like they are being 
tugged by gravity. It may be a subtle effect, but look at the two a couple 
of times, and you'll see what I mean.

The timeout object doesn't do anything--or rather, the callback handler 
doesn't do anything. It has no code other than "on timeoutHandler" and 
"end," and fires about once every 15 seconds.

Terry Schussler has a good explanation. He says that simply creating a 
timeout object makes Director (or, in this case, Shockwave), check the 
timeout object list, and that takes CPU cycles. I haven't seen the C code 
for Director, but I imagine that it probably does a quick check for a null 
pointer, and if it's not null, it calls the timeout check function.

This is a wonderful case of serendipity. I actually wanted the dragging 
effect that I get with the timeout object, not the lockstep movement you 
see without the timeout.

I worked for hours trying to get that effect, then all of a sudden, voila! 
It was there. At first I had no idea what I had done to make it work, but I 
was mighty glad to be going home before 2:00 a.m. :-)

Cordially,
Kerry Thompson


[To remove yourself from this list, or to change to digest mode, go to
http://www.penworks.com/LUJ/lingo-l.cgi  To post messages to the list,
email [EMAIL PROTECTED]  (Problems, email [EMAIL PROTECTED])
Lingo-L is for learning and helping with programming Lingo.  Thanks!]

Reply via email to