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.

spaces in a kick message

Old posts that have not been replied to for several years.
Locked
A
AW

Post by AW »

Hi, can anyone help me please, i'll appreciate it, sometime when i use kick command, and it shows spaces in a kick message, donot know why?
advance thanks
regards
AW
<AW> .k ABC tsk tsk
*** ABC was kicked by eggdrop (tsk tsk {})

here are the codes

proc kick_command {nick host handle channel args1} {
set args [split $args1 " "]
set knick [lindex $args 0]
set date [clock format [clock seconds] -format "%b %d"]
if {[test_real $nick]} {
return 0
}
if {$knick==""} { return 0 }
set reason [lrange $args 1 end]
if {$reason==""} {
set reason "..go and play outside!"
}
set kickstring "KICK $channel $knick :$date $nick: $reason"
if {[matchattr [nick2hand $knick $channel] o]==0} {
putserv "$kickstring"
} else {
if {[matchattr $handle m]==1} {
putserv "$kickstring"
} else {
set kickstring "KICK $channel $nick :Wow! Lamerrr! Ain't it amazin? (Kick attempt on +o $knick)"
putserv "$kickstring"
}
}
return 1
}


P
Petersen
Owner
Posts: 685
Joined: Thu Sep 27, 2001 8:00 pm
Location: Blackpool, UK

Post by Petersen »

lrange outputs a list. you need to join it to make it a string.
A
AW

Post by AW »

hehe thanks, and how this will be done, can you please give me an example??/
P
Petersen
Owner
Posts: 685
Joined: Thu Sep 27, 2001 8:00 pm
Location: Blackpool, UK

Post by Petersen »

set reason [join [lrange $args 1 end]]
A
AW

Post by AW »

Petersen:Thank you so much!
Locked