Ban/kick/time/Status counter

By Weasel on May 26, 2009

this script when you join gives the time of join (by timezone of mIRC with the bot running) visitor count (on joinn) when kicked it adds the kick say !listkicks and or !listbans to view the number of kicks/bans for the chan, in the code. just replace the with a chan (eg #mIRC) say !time for the time

;_____________________________________________________
;             Time/Date/Visitor/kick/ban Count
;_____________________________________________________
on *:join:#<enter your chan here>: { inc %vstr 1 | notice $nick Welcome to $chan you (we have been visited %vstr times) | notice nick you have joined at the time $asctime }
on *:kick:#<enter your chan here>: { inc %kick 1 }
on *:text:!listkicks*:#<enter your chan here>: {
 if ($nick isop #) { notice $nick current number of kicks for $chan is %kick }
 if ($nick ishop #) { notice $nick current nunber of kicks for $chan is %kick }
 if ($nick isreg #) { notice $nick only operators can use this command repeat attempts at controlling me will result in a ban }
}
on *:ban:#<enter your chan here>: { inc %ban 1 }
on *:text:!listbans*:#<enter your chan here>: {
 if ($nick isop #) { notice $nick current bans for $chan is %ban }
 if ($nick ishop #) { notice $nick current bans for $chan is %ban }
 if ($nick isreg #) { notice $nick only operators can use this command repeat attempts at controlling me will result in a ban }
}
on *:text:!time:#: { notice $nick the time is $asctime }

Comments

Sign in to comment.
gooshie   -  Sep 23, 2009
The letters can be utilized, too, instead of signs... Too bad there is no letter for admin. They should be using $nick(#,$nick,~&@%) in this snippet. When you need to $nick(#,$nick,qaoh) then the 'a' is interpeted as 'All'. Trying to compensate by using $nick(#,$nick,a,vr) does NOT work when someone has both q,a,o, or h AND ALSO has mode +v. Maybe Khaled was in too deep with the 'a' == All when &admin came along (would have been nice if 'e' == everyone). To further frustrate the issue even if we wanted to only use the symbols everywhere for consistency we dont have a symbol for 'regular' and are forced to use the letter convention. Worst case involves having to mix the letter and symbol convention as my voiceall alias in my [Basic Ops snippet](http://www.hawkee.com/snippet/6723/) was forced to do.
 Respond  
Jethro   -  Sep 19, 2009

The letters can be utilized, too, instead of signs, since mirc recognizes o for op and h for halfop:

$nick(#,$nick,oh)

But they're the same thing nevertheless.

 Respond  
gooshie   -  Sep 19, 2009
if ($nick isop #) { notice $nick current bans for $chan is %ban }
if ($nick ishop #) { notice $nick current bans for $chan is %ban }

could be combined into one line

if $nick(#,$nick,@%) { notice $nick current bans for # is %ban }

and the other one also

 Respond  
Jethro   -  Jul 10, 2009

This script has the potential to further be improved with counting joins, kicks and bans from individuals, other than counting the total kicks and bans from a channel. Using hash tables is a good idea to set about such script. A delete feature would be nicer to remove the nick of those individuals if you decided to reset. Anyway, it's just a matter of my opinion.

 Respond  
PATX   -  Jul 09, 2009

i hate {s and }s

 Respond  
Weasel   -  Jul 08, 2009

um, idk, hey um, just a tip, try sayin {code} then enter code then {/code} at the end (replace { with [)

 Respond  
Jelly   -  Jul 07, 2009

on *:join:#: { inc %vstr 1 | notice $nick Welcome to $chan you (we have been visited %vstr times) | notice nick you have joined at the time $asctime }

you dont need two notices there, you can just make it { inc %vstr | notice $nick Welcome to $chan, we've been visited %vstr times, you joined at $asctime }

Also, why is there a "you" before the parens?

Otherwise I like it :3

 Respond  
Testor   -  May 27, 2009

for the if ($nick isop #) | if ($nick ishop $chan) You could do one line: If ($nick isop $chan || $nick ishop $chan) { }

 Respond  
Are you sure you want to unfollow this person?
Are you sure you want to delete this?
Click "Unsubscribe" to stop receiving notices pertaining to this post.
Click "Subscribe" to resume notices pertaining to this post.