I’ll first start off by saying I’m a noob at Applescript studio, I’ve just completed a beginners course, and my most complicated application has been to set up a window with different tabs that can calculate a mortgage lol.
What I’m trying to do here is build a sequencer, and I need a way of expressing the following:
every 100th of a second
(Do action)
How would I go about creating a condition like the one above? Thanks a lot in advance!
-Mel.
Model: G4
AppleScript: 1.4.1
Browser: Safari 419.3
Operating System: Mac OS X (10.4)
As you’ve found, repeat loops stop execution of the app. The only application-level method you could use is the idle handler, but per the idle doc’s you should “always return a value of 1 or greater” as the idle interval. I assume that the idle command uses an implementation of NSTimer, which also takes seconds at its interval. I’m not sure what method people use to handle intervals of such a short time, but I am pretty sure that you’re not going to find a solution in applescript studio. Regardless, I don’t think it would be possible, even if you were able to fire in such short intervals. You likely wouldn’t even be able to fire the code to handle the timer in that short time, let alone some more complex code that would actually do something important. The time required to execute the code would overflow the time alloted, and you wouldn’t get reliable results. Sounds like you’re in over your head.