pipo Voice
Joined: 18 Nov 2006 Posts: 16
|
Posted: Sun Dec 31, 2006 9:59 pm Post subject: put lindex1 and lindex2 together? |
|
|
Happy New Year!!
For announcing some output of the sitebot to a second channel I use:
(example if a NEW release is send)
| Code: |
set one [lindex $nam 0]
if {[string equal NEW $one]} {
putserv "PRIVMSG #channel1 :$announce"} else {
putserv "PRIVMSG #channel2 :$announce"}
|
The problem is it wil announce, in channel1: New upload, New sample, New cover etc.
But I only want the "new upload" to be announce in channel1.
So I need to use the first and second lindex of $nam:
set one [lindex $nam 0]
set two [lindex $nam 1]
But then I dont know how to use it, so it wil announce lindex equal NEW ($one) UPLOAD ($two) to channel1. |
|