I don't believe it's "asymmetric". I'm pretty sure it happens as fast as you can tell it to.

The code I gave you makes 100 members per second on my G3
Just creating them it's more like 500 per second.

yeah, well I was thinking of also putting them on stage, using puppetsprite and assigning each sprite its own member. This is were I was worried of upsetting Director. So I tried it with the script below, triggered by a simple button.
It was fast enough, I think. Between 900-1300 milliseconds for creating 100 members and positioning them on stage. I am on OS X and trying this out in the browser (as a .dcr file). And no protesting from Director when puppeting sprites right after creating the text members. This will do nicely, methinks. And methanks!


---
on createManyTextMembers
stopwatch_start=the milliseconds
repeat with i= 2 to 101
newmem=new(#text, castLib(2))
newmem.text=string(i-1)
newmem.fontSize=9
--create sprites from 11 and upwards
puppetSprite i+10, 1
sprite(i+10).member=member(newmem.member.number)
-- never mind the loc, it looks ugly, I just want Director to draw to the stage.
sprite(i+10).loc=point(i*10, 10)
end repeat
--compare forcing Dir to redraw the stage before putting the alert up and
--stopping the timer, and not doing that - by commenting out the updatestage command.
updatestage


stopwatch_stop=the milliseconds
alert "total time:" && stopwatch_stop-stopwatch_start && "milliseconds" & RETURN &\
"started at" && stopwatch_start & RETURN &\
"stopped at" && stopwatch_stop
end
--


[To remove yourself from this list, or to change to digest mode, go to http://www.penworks.com/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