This is my first public IRC snippet ive made so please be nice ^^
It basically blocks people from pm'ing you who you dont want to pm you.
added a dialog table so easier interface, /newblist or right click in a channel window and select newb list to open
You can ban an $address | format to use is ~test@test.com
Delete a banned $address
see whos in the list
clear the whole list
Its still got all the old alias in becuase ive only just added the dialog, so you can still use the old commands without dialog if yo want :P
; mIRC Newb List Script by `AlphA^
; Version 2.0
; Email: alpha@unrealgamer.net
; IRC: irc.quakenet.org #unleashed.ut
on *:LOAD:{
/echo -a You have loaded The Newb list by `AlphA^ /newblist to enter settings, or right clcik in a channel window and select the "newb list" tab.
/echo -a Correct way of adding $address ~rifk@this.is.my.host.com
}
alias block {
if ($1 == $null) {
echo -a You must enter the newbs $address
}
ELSEIF ($1 !== @) && ($1 !== status) {
echo -a Invalid Format, The address must be added in the format *@* e.g. ~rifk@this.is.my.host.org You must include the ~ if its in their host !!
}
ELSEIF (@ isin $1) {
set %newblist %newblist $1 $chr(32) | echo -a [Newb Added] $1 Can no longer pm you
}
ELSEIF ($1 == status) {
echo -a The address currently blocked are [ %newblist ]
}
}
alias delnewb {
if ($1 isin %newblist) {
set %newblist $remtok(%newblist, $1, 32) | echo -a $1 has been removed from your newb list
}
ELSEIF ($1 !isin %newblist) {
echo -a $1 isnt in your newb list :S
}
}
on *:TEXT:*:?: {
if ($address isin %newblist) {
closemsg $nick
}
}
menu channel,query,menubar {
Newb List
.Settings:newblist
}
dialog newblist {
title "Dialog"
size -1 -1 470 322
option pixels
box "Add/del", 8, 4 50 456 129
box "Newb List", 7, 1 1 465 318
button "Del Newb", 5, 336 91 60 22
button "Add Newb", 4, 336 64 60 24
edit "Enter $address", 3, 15 93 315 20
edit "Enter $address", 2, 14 68 318 20
text " `AlphA^'s Newb List", 1, 5 20 454 23
button "Cancel", 6, 335 137 65 25, ok
box "Other", 9, 5 181 454 132
button "Status", 10, 170 227 65 25
button "Unload", 11, 303 227 65 25
button "Clear Newb List", 12, 51 138 104 25
}
on *:DIALOG:newblist:SCLICK:4: { set %newblist %newblist $did($dname,2) $chr(32) | echo -a [Newb Added] $did($dname,2) Can no longer pm you }
on *:DIALOG:newblist:SCLICK:5: { if ($did($dname,3) isin %newblist) { set %newblist $remtok(%newblist, $did($dname,3), 32) | echo -a [Newb Deleted] $did($dname,2) Can now pm you again ! }
ELSE { echo -a [ERROR] The address you specified isnt in my newb list, Check the status for the newbs in my list. }
}
on *:DIALOG:newblist:SCLICK:10: { block status }
on *:DIALOG:newblist:SCLICK:12: { unset %newblist | echo -a Newb List Cleared }
on *:DIALOG:newblist:SCLICK:11: { unload -rs newblist }
alias newblist { dialog -mrv newblist newblist }
on *:UNLOAD:{
echo -a `AlphA^'s Newb List has been unloaded.
}