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.

kill script

Old posts that have not been replied to for several years.
Locked
n
ningo

kill script

Post by ningo »

ok i got this code

Code: Select all

proc killlog_log {nick host hand chan kill} {
	global killlog_setting
	if {([string match -nocase "killed*" $kill]) || ([string match -nocase "autokilled*" $kill]) || ([string match -nocase "kline*" $kill]) || ([string match -nocase "SVSKill*" $kill])} {
		if {($killlog_setting(logghost)) || (![string match -nocase "Killed (NickServ (Ghost*" $kill])} {
			killlog_putkilllog $nick $host $chan $kill
		}
	}
}
what do i have to change that the bot doesn't log channel killmessages, but the servermessages, wich are send when you kill someone?
i suggest ist something up here

Code: Select all

{nick host hand chan kill}
i have really no clue of tcl :P
thx for help :D
User avatar
awyeah
Revered One
Posts: 1580
Joined: Mon Apr 26, 2004 2:37 am
Location: Switzerland
Contact:

Post by awyeah »

This is not the full procedure.
This code points to another procedure.

Code: Select all

killlog_putkilllog $nick $host $chan $kill
We would need to see all of the script to determine this
hopefully. Like what function does this new procedure
do and what output does it give!
·­awyeah·

==================================
Facebook: jawad@idsia.ch (Jay Dee)
PS: Guys, I don't accept script helps or requests personally anymore.
==================================
n
ningo

Post by ningo »

sorry, here is the rest

Code: Select all

proc killlog_putkilllog {nick host chan kill} {
	global killlog_setting
	set databaseid [open $killlog_setting(logdb) a+]
	puts $databaseid "<tr><td align=left bgcolor=$killlog_setting(tablecell_color_1)><font size=\"4\">[clock format [clock seconds] -format "%I:%M:%S %p %x"]</font></td>"
	puts $databaseid "<td align=left bgcolor=$killlog_setting(tablecell_color_2)><font size=\"4\"><center>$nick</center></font></td>"
	puts $databaseid "<td align=left bgcolor=$killlog_setting(tablecell_color_1)><font size=\"4\"><center>$host</center></font></td>"
	puts $databaseid "<td align=left bgcolor=$killlog_setting(tablecell_color_2)><font size=\"4\"><center>$kill</center></font></td>"
	puts $databaseid "<td align=left bgcolor=$killlog_setting(tablecell_color_1)><font size=\"4\"><center>$chan</center></font></td></tr>"
	close $databaseid
	set logid [open $killlog_setting(log) a+]
	puts $logid "KILL: $nick - $host - $kill"
	close $logid
	set killpageid [open $killlog_setting(page) w]	
	puts $killpageid "<html>"
	puts $killpageid "<head>"
	puts $killpageid "<title>Kill Log</title>"
	puts $killpageid "<META NAME=\"description\" CONTENT=\"Kill Log\">" 
	puts $killpageid "<META NAME=\"keywords\" CONTENT=\"kill, akill, kline, stats, ircd, irc, server, clones, abuse, flood\">"
	puts $killpageid "</head>"
	puts $killpageid "<body bgcolor=$killlog_setting(bgcolor)>"
	puts $killpageid "<font size=\"6\" color=$killlog_setting(textcolor)><center>Kill Log</center></font><br>"
	puts $killpageid "<center>"
	puts $killpageid "<table>"
	puts $killpageid "<tr>"
	puts $killpageid "<td align=left bgcolor=$killlog_setting(tableheader_color_1)><font size=\"5\"><center>Time</center></font></td>"
	puts $killpageid "<td align=left bgcolor=$killlog_setting(tableheader_color_2)><font size=\"5\"><center>Nick</center></font></td>"
	puts $killpageid "<td align=left bgcolor=$killlog_setting(tableheader_color_1)><font size=\"5\"><center>Host</center></font></td>"
	puts $killpageid "<td align=left bgcolor=$killlog_setting(tableheader_color_2)><font size=\"5\"><center>Kill</center></font></td>"
	puts $killpageid "<td align=left bgcolor=$killlog_setting(tableheader_color_1)><font size=\"5\"><center>Channel</center></font></td>"
	puts $killpageid "</tr>"
	set databaseid [open $killlog_setting(logdb) r]
	while {![eof $databaseid]} {
		gets $databaseid line
		puts $killpageid $line
	}
	close $databaseid
	puts $killpageid "</table>"
	puts $killpageid "<br>"
	puts $killpageid "<br>"
	puts $killpageid "<font color=$killlog_setting(textcolor)>Last Updated: [clock format [clock seconds] -format %D] [clock format [clock seconds] -format "%I:%M %p"]</font>"
	puts $killpageid "</center>"
	puts $killpageid "</body>"
	puts $killpageid "</html>"
	close $killpageid
	putlog "[killlog_dopre]$nick has been killed. \($chan\)"
}
putlog "\002KILLLOG:\002 KillLog.tcl Version 2.0 by Wcc is loaded."
putlog "\002KILLLOG:\002 Logging kills as html to $killlog_setting(page)."
putlog "\002KILLLOG:\002 Logging kills as text to $killlog_setting(log)."
Locked