Triggers?
Displaying 1-5 of 5 total.
1
Please enter a numerical value for the importance of this sticky.
Enter 0 to unsticky.
mcgrue

Mayhaps there should be some system.vc callfunc type deals for global events? While finishing the kittens game, it occurs to me that global optional callfuncs along the lines of 'onAppFocus' and 'onAppBlur' would be handy.

Maybe like have a System.onAppFocus or Verge.onAppFocus or somesuch as a read/write string, and if you set it to a system.vc functionname it calls that function when the specified system trigger is called.

Verge.onAppBlur = 'pauseGame'; //would be mighty good.

Just a thought I'm having right now. Back to the Kitten-makery!

Posted on 2005-05-30 23:06:26

Overkill

Maybe even onClose action, too. I mean, there is the odd time you might want a final event to be triggered before Verge just closes. Of course, one would have to be careful with this type of power not to have anything like infinite loops or whatnot.

Say, you had a save-on-exit type deal and you didn't want people to get pissed when the file doesn't save because they chose to click the X and not hit escape. This might make such functionality useful. Or maybe, if someone wanted the screen and music to fade when they closed it.

Then again, maybe it's not such a great idea, because on the rare occasion, V3's timer isn't initialized or incremented and that means if there's a loop waiting on the timer before you can exit, you'll never be able to exit your program.

Posted on 2005-06-01 14:48:28

Gayo

OnClose would be AWESOME, especially if it could end with the close being aborted, so you could do an 'are you sure you want to quit without saving?' prompt and let them choose 'Cancel.' Sure, people could fuck it up so that you can't close at all, but that's what alt+ctrl+del is for.

Posted on 2005-06-01 18:28:32

mcgrue

Jesse, what's the mac version of ctrl-alt-del?

Posted on 2005-06-02 10:58:08

Jesse

Command-Option-Escape, aka force quit.

Posted on 2005-06-05 13:56:25


Displaying 1-5 of 5 total.
1
 
Newest messages

Ben McGraw's lovingly crafted this website from scratch for years.
It's a lot prettier this go around because of Jon Wofford.
Verge-rpg.com is a member of the lunarnet irc network, and would like to take this opportunity to remind you that regardless how babies taste, it is wrong to eat them.