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.

Random Nicks

Help for those learning Tcl or writing their own scripts.
Post Reply
Z
Zorb
Voice
Posts: 22
Joined: Tue Oct 17, 2006 8:14 am

Random Nicks

Post by Zorb »

Wondering how I would be able to select a random choice from about 5 nicks in the channel.

Bot
Bot2
Bot3
Bot4
Bot5

I'd like to be able to randomly choose one of them (not the bot that is running the script) and notice the bot to do something.
User avatar
Sir_Fz
Revered One
Posts: 3794
Joined: Sun Apr 27, 2003 3:10 pm
Location: Lebanon
Contact:

Post by Sir_Fz »

Code: Select all

set botslist {bot1 bot2 bot3 bot4 bot5}

set randombot [lindex $botslist [rand [llength $botslist]]]
Post Reply