This is the new home of the egghelp.org community forum.
All data has been migrated (including user logins/passwords) to a new phpBB version.


For more information, see this announcement post. Click the X in the top right-corner of this box to dismiss this message.

bind time

Old posts that have not been replied to for several years.
Locked
User avatar
DrTongue
Op
Posts: 115
Joined: Sat Jan 26, 2002 8:00 pm
Location: Orlando, Florida
Contact:

Post by DrTongue »

Try to make bot send message to channel at specified time of the hour, EVERY hour. I have what I THOUGHT to send message at 10 minutes past every hour:

bind time - "*10***" texttime

proc texttime {n h handle ch te} {
global text channel
foreach chan $channel {
putserv "PRIVMSG $chan :$text"
}
}

(Should it be "*10***" or "* 10 * * *" ??)
What I have now works PERFECT at 10 minutes after every hour till it reaches 10 a.m. Then it starts doing it every minute till 11 a.m and then goes back to once every 10 minutes after the hour. I'm sure it's something I have written incorrect, any suggestions?



<font size=-1>[ This Message was edited by: DrTongue on 2002-04-02 16:51 ]</font>
P
Petersen
Owner
Posts: 685
Joined: Thu Sep 27, 2001 8:00 pm
Location: Blackpool, UK

Post by Petersen »

you've answered ya own question. should be * 10 * * *
M
Mordred

Post by Mordred »

I was looking at my earlier reply and I misinformed you. Sorry. In my example I got the Hour and Minute fields mixed up. The syntax for bind time is as follows:

bind time <flags> "<minutes> <hours> <day> <month> <year>" proc

therefore to get it going every 10 minutes I'd try:

bind time - "*0 * * * *" proc

signifies that it should execute whenever the minute counter has a zero in it. I don't know if that works, but the above syntax is correct now anyhow.
User avatar
DrTongue
Op
Posts: 115
Joined: Sat Jan 26, 2002 8:00 pm
Location: Orlando, Florida
Contact:

Post by DrTongue »

Thank you both very much !!!
Locked