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.

auto limit & kick report & kicked count

Old posts that have not been replied to for several years.
User avatar
cambodia
Halfop
Posts: 73
Joined: Sun Aug 22, 2004 1:03 am
Location: cambodia

Post by cambodia »

ok all work great but can modify it bit more easy ,
this is old formate

-----------------------------------------------------------------
Kicked from #thailand by Danoy!~PeteR@203.144.67.x154c with reason: Danoy
Kicked from #thailand by Danoy!~PeteR@203.144.67.x154c with reason: Danoy
Kicked from #khmer by !cambodia.uirc.net with reason: Danoy
Kicked from #khmer by !cambodia.uirc.net with reason: Danoy
Kicked from #thailand by Danoy!~PeteR@203.144.67.x154c with reason: Danoy
-----------------------------------------------------------------

any code to make it record date & time example

[18 march 2005 : 13:02] i got kicked out from #thailand by danoy!~peter@203.144.67.x154c with reason : danoy

which code to record date & time ( and if possible each day will seperate by ------------------------ so it easy to look into it :) )

sorry to bother you but seem this is final step now because all done just wanna change it to look better , many thank sir_fz you look great :)
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

[ctime [unixtime]]
this will return for example: Fri Mar 18 09:11:55 2005
User avatar
cambodia
Halfop
Posts: 73
Joined: Sun Aug 22, 2004 1:03 am
Location: cambodia

Post by cambodia »

Sir_Fz wrote:

Code: Select all

[ctime [unixtime]]
this will return for example: Fri Mar 18 09:11:55 2005
i have done this and it work now just not yet work with seperate it into line by date :)

Code: Select all

set bkickfile "bkick.log" 
set bkickrelay "#channel" 
set dtime [ctime [unixtime]]
bind kick - * relay:kick 

proc relay:kick {nick uhost hand chan targ rsn} { 
 if {[string equal -nocase $::botnick $targ]} { 
  set logtime [ctime [unixtime]]
  logbkick "$logtime : Kicked from $chan by $nick!$uhost with reason: $rsn" 
  puthelp "PRIVMSG $::bkickrelay :Kicked from $chan by $nick!$uhost with reason: $rsn" 
 } 
} 

proc logbkick {text} { 
puts [set fs [open $::bkickfile a]] "$text" 
close $fs 
}
i find it in other forum and try it then work fine :) thank all :D
User avatar
caesar
Mint Rubber
Posts: 3778
Joined: Sun Oct 14, 2001 8:00 pm
Location: Mint Factory

Post by caesar »

Off topic: Why not using 'isbotnick' instead of 'string match -nocase'? Should be faster this way..
Once the game is over, the king and the pawn go back in the same box.
User avatar
Sir_Fz
Revered One
Posts: 3794
Joined: Sun Apr 27, 2003 3:10 pm
Location: Lebanon
Contact:

Post by Sir_Fz »

caesar wrote:Off topic: Why not using 'isbotnick' instead of 'string match -nocase'? Should be faster this way..
Yeah, why not :P
User avatar
cambodia
Halfop
Posts: 73
Joined: Sun Aug 22, 2004 1:03 am
Location: cambodia

Post by cambodia »

i notice that this script not save all kicked , example it should be continue count of kicked person but it look reset every day , can add line for saving kicked count into file and call back and plus with new kicked and display ? :D
Locked