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.

a timer question

Old posts that have not been replied to for several years.
Locked
d
drewila

a timer question

Post by drewila »

I need to make a timer that is equivalent of:

Code: Select all

//msg =bud .tcl ultranews - - - #channel $rand(1,10)
So that the bot does it by itself (so that I don't have to run a timer on mIRC). I know nothing about this sort of scripting, so detailed replies would be highly appreciated.

Thanks
d
drewila

Post by drewila »

By the way, the "$rand(1,10)" variable is read as "insert a number of one through ten" on mIRC.
User avatar
GodOfSuicide
Master
Posts: 463
Joined: Mon Jun 17, 2002 8:00 pm
Location: Austria

Post by GodOfSuicide »

drewila wrote:By the way, the "$rand(1,10)" variable is read as "insert a number of one through ten" on mIRC.

Code: Select all

[expr [rand 10] +1] <-- the same for TCL (rand generates from 0 - 9, so add the +1)
User avatar
caesar
Mint Rubber
Posts: 3778
Joined: Sun Oct 14, 2001 8:00 pm
Location: Mint Factory

Post by caesar »

From the [rand 10] will result a random number betwen 0 and 9 so to make it actualy be betwen 1 and 10 we add 1 to the rand result like: [expr [rand 10] +1] :P
Once the game is over, the king and the pawn go back in the same box.
User avatar
GodOfSuicide
Master
Posts: 463
Joined: Mon Jun 17, 2002 8:00 pm
Location: Austria

Post by GodOfSuicide »

caesar wrote:From the [rand 10] will result a random number betwen 0 and 9 so to make it actualy be betwen 1 and 10 we add 1 to the rand result like: [expr [rand 10] +1] :P
isnt that exactly what i postet befor ? you allready have your rank, you dont have to spam
User avatar
caesar
Mint Rubber
Posts: 3778
Joined: Sun Oct 14, 2001 8:00 pm
Location: Mint Factory

Post by caesar »

The code you've posted is correct, I haven't said that. :P I've gave the explanation if anyone needs it. :)
Once the game is over, the king and the pawn go back in the same box.
User avatar
GodOfSuicide
Master
Posts: 463
Joined: Mon Jun 17, 2002 8:00 pm
Location: Austria

Post by GodOfSuicide »

ah, i c...

firecars are red
you know, like little rabbits that have just been shot :P
Locked