Re: Idling Newbie
Re: Idling Newbie
- Subject: Re: Idling Newbie
- From: Chris Nebel <email@hidden>
- Date: Sat, 06 Jan 2001 17:42:13 -0800
- Organization: Apple Computer, Inc.
Xandra Lee wrote:
>
My partner is unable to stop playing Snood, so before bankruptcy hits,
>
I'd like to write an Applescript that would force him to Quit after an
>
hour, (ideally giving him a 5 minute warning).
I know the feeling!
>
With all the talk about crashing with idle handlers, I was leery about
>
experimenting with this one.
The crashing-idle-handler bug doesn't affect everyone, and only happens
with 9.0 and 9.0.4, or more precisely, with AppleScript 1.4.x. cris, who
was the first person to report it that I know of, says you can dodge it by
installing AppleScript 1.3.7; and we've been unable to reproduce it on Mac
OS 9.1, which should be out Real Soon Now.
>
The following ran OK until I tried running
>
while I was actually playing a game
>
>
Two issues While actually playing the game:
>
the game takes control of the Mac: unless the user types a pause
>
command, one can't access anything.
>
Typing command-Q (the only way to access the menu) just quits the
>
current game and returns user to main screen, the NEXT "Quit command,
>
quits the game.
These are a bit more serious. Because of the way Mac OS multi-tasking
works, if Snood won't share processor time with anything, there's not much
you can do about it. Because it's an option, you could just turn it off
and hope that your partner doesn't notice. On a fast enough machine, it
doesn't make any real difference to game play.
Trying it myself, I find that Snood seems to ignore quit events sent while
a game is in progress, so just saying 'tell application "Snood" to quit'
may not do you any good. I'd suggest some sort of key-typing scripting
addition, and have it send two command-Q's in a row, maybe with a small
delay in between.
An alternate suggestion from *my* partner, who was addicted to Snood
herself in the past, is to get him switched over to Deathground by
Freeverse Software (www.freeverse.com). Remember, of course, that heroin
was developed in order to cure people of opium addiction...
--Chris Nebel
AppleScript Engineering