Register to post in forums, or Log in to your existing account
 

Play RetroMUD
Post new topic  Reply to topic     Home » Forums » zMUD General Discussion
kiyonisis
Newbie


Joined: 22 Mar 2005
Posts: 5

PostPosted: Tue Jun 28, 2005 5:35 pm   

Help on creating a reminder trigger
 
I want to make a trigger which will involve finding how much time has elapsed from a given time stamp.

I have no idea where to start, but the general premise is that I'll have an alarm to remind me to do something if it has been greater than 12 hours since the last time I did that action. The catch is, this still needs to function if I am not using zmud, i.e. if I Make the timestamp at midnight and log off, it should count any time after noon the next day as more than 12 hours having elapsed. Can anyone help?
Reply with quote
Full Throttle
Wanderer


Joined: 07 Dec 2004
Posts: 65

PostPosted: Tue Jun 28, 2005 7:16 pm   
 
I would use an external script for this problem.

Create a time stamp at an event:

Code:
#var time %mss(now)


Then check if the difference between the current time and the event time is more than 11 hours 59 minutes 59 seconds:

Code:
#alias check {
#mss {hourdiff = datediff~(~"h~", ~"@time~", now)}
#if (%mss(hourdiff) > 11) {#echo ALERT!}}


If VBScript is not an available scripting language on your computer, then you can download Microsoft Windows Script 5.6 here:

http://msdn.microsoft.com/library/default.asp?url=/downloads/list/webdev.asp

You have to check "Allow VBScript" in preferences/script parser within zMUD.
Reply with quote
Display posts from previous:   
Post new topic   Reply to topic     Home » Forums » zMUD General Discussion All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum

© 2009 Zugg Software. Hosted by Wolfpaw.net