Revolution much slower then Hypercard
Geoff Canyon
gcanyon at inspiredlogic.com
Mon Feb 11 18:19:01 EST 2002
I don't know if there is any way to change this, but it seems the fastest Revolution will "click" is about 4 times a second (on my computer). This is true even if it isn't doing anything -- not painting, messages locked, just clicking on the card.
The following, on the other hand, runs in about 15 ticks, or a quarter of a second. Obviously it could be further optimized and also needs to be customized to your purpose.
on mouseUp
lock messages
lock screen
put 300 into XX
put 300 into YY
put 200 into RR
put -((pi/2)-(pi/584)) into Rad
set the style of the templateGraphic to "oval"
repeat until Rad>=1.5*pi or the optionKey is "down"
put XX+round(RR*cos (Rad)) into tX
put YY+round(RR*sin (Rad)) into tY
set the rect of the templateGraphic to tX-2,tY-2,tX+2,tY+2
create graphic
add (2*pi)/584 to Rad
end repeat
end mouseUp
If you really need paint graphics, then execute the above script and then take a screen shot. (you can do that within Revolution)
Note that this script creates a large number of graphics. Selecting and deleting them by hand will be very slow. A script that deletes them all with the screen locked would be much faster. You can make this easier by giving them all the same name in the "create graphic" step.
regards,
Geoff
More information about the use-livecode
mailing list