# # - + Welcome to PhoEniX Version 2.13 from Vassago + - # - + The ORIGINAL PHOENIX/GARGOYLE -*- Accept no Hacks or Substitutes + - # -* Release Date: 03/27/95 *- # # This script works with all 2.2.9 and greater clients (at this point in # time). It will not work on VMS or similar systems. 2.3.17 clients and # variations thereof may cause irregular script behavior. AIX and similar # systems may experience unusual results from the script /SVE function. # # This script is NOT compatible with any other scripts, with the exception # of the other files that are included with it and my extras, pkicks, # annoy, VeveS, and Serpent scripts. I only guarantee PhoEniX to be # backdoor free if you download it from my Public Domain FTP site: # # jcowan.reslife.okstate.edu # # If you have problems, delete your .ircrc and/or make sure you are # untarring the tarfile (tar -xvf ). If problems persist, # get a fresh copy from my FTP site (jcowan.reslife.okstate.edu) # # - Vassago (Ryan Addams) # ^set NOVICE OFF ^set EXEC_PROTECTION OFF echo .-------------------------------------------------------------------------. EVAL echo | __________ /\\___ ________/\\_________/\\ .__ ___ ____ _____ | EVAL echo | /_______ \\_ | \\::/ _____ ______ . \\| \\| | |/ / | EVAL echo | .::| |/ / \\/ /| \\ ___|:/ \\ ` \\ |\\ | /::. | EVAL echo | .::::| _____/ | \\ \\| \\ | \\ \\ \\ |/ _ \\::::. | EVAL echo |::::::| |:\\_____| \\________/____ \\___\\ \\_|____| \\:::::.| EVAL echo |::::::| |:::::::|______/:::::::::::\\______/::|______/:::::|______\\:::::| echo | : : (< MiSTRaL / PaRaLLaX >) | echo | PhoEniX Version 2.13 by Vassago - Accept No Hacks or Substitutes! | echo |-------------------------------------------------------------------------| EVAL echo | = Type /COMMANDS for a list of commands \(PHOENIX.HLP must be loaded\). = | echo | To get the latest version of PhoEniX, ftp to jcowan.reslife.okstate.edu | echo |  DO NOT use this script unless you get it directly from my FTP site!  | echo `-------------------------------------------------------------------------' ### Customizable Section assign fingermsg Running PhoEniX v2.13 by Vassago with epic mods by skullY assign pingmsg Pong! assign versionmesg Running PhoEniX v2.13 by Vassago with epic mods by skullY assign default_server irc.core.com 6667 assign flood_msg Flood protection activated. You are now being ignored. assign ex [E/X] assign pk | PhoEniX | assign abkickmsg | Auto BKick | assign channel_floodmsg | Channel Flood | assign nick_floodmsg | Nick Flood | assign uban_kickmsg | User Ban | assign ignore_types MSGS CTCP NOTICES INVITES NOTES CRAP assign defumes Be back in a few... assign idlemes Automatically set away. assign signmsg I'm outta here! assign shell_pgm bash assign usermode +wis assign false_files null zero yes true false lice* assign false_chars ** ** ** ** ** *;* ** ** *$$* */* # Sensor Settings (Flood/Mass Protection) @ msgsensor = 6 @ noticesensor = 10 @ ctcpsensor = 4 @ nicksensor = 3 @ msensor = 2 @ ksensor = 3 @ dcclimit = 8 @ resetcount = 16 @ ignorecount = 300 # Default Assigns (Can be changed while online) assign extmes ON assign floodp ON assign chanprot ON assign idle_time 5 assign prot ON assign nhp OFF assign rejoin ON assign autochannels ALL assign ctcpauto ON assign autorename ON assign autoop on assign TOOPVIEW OFF assign AUTOGET ON assign AUTOSEND ON assign AUTOCLOSE OFF assign SECURITY OFF assign AUTOCLOSEWHENAWAY OFF assign NOISE ON assign OVERWRITE OFF # PhoEniX Directories ($W designates current directory) # If you aren't on SunOS, you might want to change $HOME to ~ if you are # having problems with the script trying to write to a strange directory. EVAL ^assign PhoEniXDir $HOME/.PhoEniX EVAL ^assign MainDir $W EVAL ^assign UPLOADDIR $W EVAL ^assign DOWNLOADDIR $W ### End Customize Section ### Initializers assign SCRIPTLOADING YES ^set status_format [%T] %*%@%N%#%S%H%B%Q%A%C%+%I%O %M%F %W%>%U EVAL ^assign OLD_STATUS $STATUS_FORMAT EVAL echo $ex PhoEniX Version 2.13 now loading, please wait... @ mcount = 0 @ kcount = 0 @ msgcount = 0 @ noticecount = 0 @ ctcpcount = 0 @ dccsent = 0 @ nickcnt = 0 @ away_messages = 0 @ logged_entries = 0 @ msgmax = 10 @ MYSEND = [NO] @ FRIENDADD = 0 @ PRIVADD = 0 @ ENEMYADD = 0 @ COMMENTADD = 0 @ GETCOUNT = 0 @ TOTPACK = 0 EVAL ^assign asve $PhoEniXDir/save.ex EVAL ^assign baksve $PhoEniXDir/exsave.ex EVAL ^assign awayfle $PhoEniXDir/away.ex EVAL ^assign offerfile $PhoEniXDir/offer.ex EVAL ^set logfile $MainDir/irclog.ex EVAL ^assign flood_ok $help_service assign defban h assign ban_name HOST assign change_stat ON assign showkill ON assign awaystat ON assign OPVIEWING OFF assign isaway NO assign logirc OFF assign bogus_patterns *fuck* *shit* *suck* *dick* *penis* *cunt* *haha* *fake* *split* *ass* *hehe* *bogus* *yawn* *leet* set AUTO_UNMARK_AWAY OFF set AUTO_WHOWAS OFF set BEEP ON set BEEP_MAX 3 set BEEP_ON_MSG NONE set BEEP_WHEN_AWAY OFF set BOLD_VIDEO ON set CHANNEL_NAME_WIDTH 12 set CLOCK ON set CLOCK_24HOUR ON set CLOCK_ALARM NULL set COMMAND_MODE OFF set CONTINUED_LINE set DCC_BLOCK_SIZE 1024 set DISPLAY ON set FLOOD_WARNING OFF set FULL_STATUS_LINE ON set HELP_WINDOW OFF set HIDE_PRIVATE_CHANNELS OFF set HIGHLIGHT_CHAR BOLD set HISTORY 25 set HOLD_MODE OFF set INDENT ON set INPUT_PROMPT [E/X] set INPUT_PROTECTION ON set INSERT_MODE ON set INVERSE_VIDEO ON set LASTLOG 40 set LASTLOG_LEVEL ALL DCC set LOG OFF set MAIL 1 set MAX_RECURSIONS 200 set NO_CTCP_FLOOD ON set NOTIFY_ON_TERMINATION OFF set SCROLL ON set SEND_IGNORE_MSG ON set SHOW_AWAY_ONCE ON set SHOW_CHANNEL_NAMES ON set SHOW_END_OF_MSGS ON set SHOW_NUMERICS OFF set SHOW_STATUS_ALL ON set SHOW_WHO_HOPCOUNT ON set STATUS_AWAY (A) set STATUS_CHANNEL %C set STATUS_CHANOP @ set STATUS_CLOCK %T set STATUS_HOLD *MORE* set STATUS_MODE (+%+) set STATUS_MAIL M:%M set STATUS_NOTIFY A:%F set STATUS_OPER * set STATUS_OVERWRITE (ow) set STATUS_QUERY Q:%Q set STATUS_UMODE (+%#) set STATUS_USER E/X set STATUS_WINDOW ^ set SUPPRESS_SERVER_MOTD ON set TAB ON set TAB_MAX 3 set UNDERLINE_VIDEO ON set USE_OLD_MSG OFF set USER_WALLOPS ON set VERBOSE_CTCP ON set WARN_OF_IGNORES ON bind ^B self_insert bind ^_ self_insert bind ^V self_insert bind ^F self_insert bind ^O self_insert bind ^X switch_channels bind ^I parse_command ^getmsg 1 $msglist bind ^R parse_command ^getmsg -1 $msglist bind ^D parse_command wholeft # Creates the PhoEniX directory EVAL ^cd $PhoEniXDir wait EVAL if ([$W]!=[$PhoEniXDir]) { EVAL ^exec -name phoenix mkdir $PhoEniXDir wait %phoenix EVAL ^exec -name phoenix chmod 700 $PhoEniXDir wait %phoenix } EVAL ^cd $MainDir wait ### Basic Aliases alias ww whowas alias scan names $C alias sc names $C alias bans sb alias n notice alias wi whois alias unignore noig alias chops w -chops alias re redirect alias c mode $C $0- alias dr //dcc rename alias dl //dcc list alias dc //dcc chat alias dcg //dcc close get alias ex exec alias wii whois $0 $0 alias ls exec ls -al alias cat exec cat alias r msg , $0- alias m msg alias bklist listbk alias umode mode $N alias chat //dcc chat $decode($chatter) alias nochat //dcc close chat $decode($chatter) alias rmode ^set status_mode (+%+) alias nokey quote MODE $C -k $decode($chankey) alias nnotice quote NOTICE $0 :$1- alias kkick quote KICK $0 $1 :$2- alias mmode quote MODE $0- alias unbanlop nunbanlop $C $0- alias mc quote MODE $C -lsnmpitk $decode($chankey) alias ml quote MODE $C +inst-lmpk $decode($chankey) alias mn quote MODE $C +nst-ilmpk $decode($chankey) alias _checkkey if (!rmatch($M *k*)) {^set status_mode (+%+)}{^timer 15 _checkkey} alias sec_check if (rmatch($0 $SECLIST)) {@ FUNCTION_RETURN = [YES]}{@ FUNCTION_RETURN = [NO]} alias wl wholeft alias wh who -host alias ap autoping alias i inv $, alias bkick bk alias deop dop alias masskick mass k alias dop ndop $C $0- alias lk mass lk alias submode if (mcount>0) {@ mcount = mcount - 1} alias subkick if (kcount>0) {@ kcount = kcount - 1} alias chanpass if ((match($strip(# $0) $AutoChannels))||([$AutoChannels]==[ALL])) {^assign FUNCTION_RETURN YES} alias enickonly {^assign FUNCTION_RETURN $encode($left($index(! $0) $0))} alias userdomain @ function_return = LEFT($INDEX(@ $0) $0)##[@]##MID(${1+INDEX(. $0)} 99 $0) alias pecho {^xecho -level crap $ex $0-} alias pubact if (isop($N $1)) {/kkick $1 $0 $channel_floodmsg} alias pubecho if ([$1]==[$C]) {/echo <$0> $2-}{/echo <$0:$1> $2-} alias safe {^assign FUNCTION_RETURN $strip(\;#\(\)+*/\\=\{\}<>[]!$$%^~`,?|'\"  $0-)} alias safe2 {^assign FUNCTION_RETURN $strip(\;#\(\)+*/\\=\{\}<>[]$$%^~`,?|'\"  $0-)} alias hignore @ function_return = fixname($0) ## [@] ## fixdomain($1) alias join if ((![$0])||([&]==[$[1]0])||([#]==[$[1]0])||([$0]==[0])||([-]==[$[1]0])) { //join $0- } { //join #$0- } alias leave if (![$0]) { //leave $C } { if (([&]==[$[1]0])||([#]==[$[1]0])||([$0]==[*])) { //leave $0 } { //leave #$0 } } alias j join alias l leave alias autoping { ^set STATUS_USER Lag ? - E/X quote PING $time() $S } alias sb { ^on ^367 "*" { if ([$4]) {/echo *** $1 $2 \(By $3, $mid(4 15 $stime($4))\)} {/echo *** $1-} } if ([$0]) {//mode $0 +b} {//mode $C +b} } alias w { if ([$0]) { if ([$0]==[-chops]) {//who $0 $C $1-} {//who $0-} } {//who *} } alias t { if ([$0]==[#*]) {//topic $0-} {//topic $C $0-} } alias inv { if ([$0]) { if ([$1]) {//invite $0-} {//invite $0 $C} } {/pecho You need to specify a nick to invite.} } alias serv { if ([$0]) {//server $0-} {//server $default_server} } alias pubcat { if ([$0]) {^exec -name pubcat cat $0} {/pecho Usage: /pubcat } } alias fing { if ([$0]) {/ctcp $0 FINGER} {/ctcp $C FINGER} } alias ver { if ([$0]) {/ctcp $0 VERSION} {/ctcp $C VERSION} } alias p { if ([$0]) {//ping $0} {//ping $C} } alias op { mmode $C +ooo $0 $1 $2 if ([$3]) {/op $3-} } alias v { mmode $C +vvv $0 $1 $2 if ([$3]) {/v $3-} } alias ndop { mmode $0 -oo $1 $2 if ([$3]) {/ndop $0 $3-} } alias dv { mmode $0 -vvv $1 $2 $3 if ([$4]) {/dv $0 $4-} } alias dcc { //dcc $0- if ([$0]==[SEND]) { @ dccsent = dccsent + 1 ^timer 120 checksend $1 $2 } } ### Error Message Editing/Commenting on ^404 "*" check_synch $0- on ^482 "*" check_synch $0- alias check_synch { if ([$0]!=[$desynch]) { if ([$0]!=[$S]) { pecho $0 is desynched from the IRC Network. ^assign desynch $0 ^timer -delete 821 ^timer -refnum 821 180 ^assign -desynch } {/echo *** $1-} } } ### MODE and KICK Protection (by Vassago) alias mdact { if ((isop($N $1))&&([$mdwait]==[])&&([$decode($0)]!=[$N])) { mmode $1 -o $decode($0) pecho MASS DEOP DETECTED. By: $decode($0) On: $1 ^assign mdwait YES ^timer -delete 793 ^timer -refnum 793 8 ^assign -mdwait } @ mcount = 0 } alias kact { if ((isop($N $1))&&([$kwait]==[])&&([$decode($0)]!=[$N])) { mmode $1 -o $decode($0) pecho MASS KICK DETECTED. By: $decode($0) On: $1 ^assign kwait YES ^timer -delete 794 ^timer -refnum 794 8 ^assign -kwait } @ kcount = 0 } alias mdtest { if ([$0]==[$lastmd]) { @ mcount = mcount + $2 ^timer 12 submode if (mcount>msensor) {/mdact $0 $1} } { ^assign lastmd $0 @ mcount = $2 ^timer 12 submode if (mcount>msensor) {/mdact $0 $1} } } alias ktest { if (([$0]==[$lastmdk])&&([$0]!=[$encode($N)])) { @ kcount = kcount + 1 ^timer 12 subkick if (kcount>ksensor) {/kact $0 $1} } {^assign lastmdk $0} } ### MODE & KICK Handlers (by Vassago & YaZoO) on -raw_irc "% MODE *" { @ mdcnt = 0 @ nixcnt = 0 ^assign mde + ^assign mdech $3 ^assign nix $4- ^assign mdchop $encode($left($index(! $0) $0)) if (([$prot]==[ON])&&(rmatch($3 -ooo* *-ooo*))) {/mdact $mdchop $2} while (mid($mdcnt 1 $mdech)!=[]) { ^assign mdecc $mid($mdcnt 1 $mdech) if (([$mdecc]==[-])||([$mdecc]==[+])) {^assign mde $mdecc} { if (match($mde$mdecc +b -b +o -o +k -k +l -l +m -m)) { if ([$mde$mdecc]==[+b]) { #if ((match($word($nixcnt $nix) $ownadd))&&(rmatch($0 *!*))) {/bansave $2 $mdchop $word($nixcnt $nix)} if ((!rmatch($0 *!*))&&(isop($N $2))&&([$nhp]==[ON])&&([$SAVEBAN]==[])) {/mmode $2 -b $word($nixcnt $nix)} ^assign -SAVEBAN } if ([$mde$mdecc]==[+o]) { if ((!rmatch($0 *!*))&&(isop($N $2))&&([$nhp]==[ON])) {/mmode $2 -o $word($nixcnt $nix)} } if ([$mde$mdecc]==[-o]) { if ([$prot]==[ON]) {/mdtest $mdchop $2 1} } if ([$mde$mdecc]==[+k]) { if ((rmatch($word($nixcnt $nix) $false_chars))&&(rmatch($0 *!*))) { ^set status_mode DEFLECTED! ^timer 15 _checkkey if ((isop($N $2))&&([$chanprot]==[ON])) {/mmode $2 -k $word($nixcnt $nix)} } {/if ((!rmatch($0 *!*))&&(isop($N $2))&&([$NHP]==[ON])) {/mmode $2 -k $word($nixcnt $nix)}} ^assign chankey $encode($word($nixcnt $nix)) } @ nixcnt = nixcnt + 1 } } @ mdcnt = mdcnt + 1 } } #on ^mode "%.% *" pecho SERVER MODES DETECTED. In $1: \'$2-\' alias bansave { if (isop($N $0)) { mmode $0 -ob $decode($1) $2 kkick $0 $decode($1) $uban_kickmsg } ^assign SAVEBAN YES pecho BAN ON YOU DETECTED. By: $decode($1) log You were banned from $0 by $decode($1)\. } on -raw_irc "% KICK *" { ^assign kickchan $strip(: $2) ^assign kickperson $encode($left($index(! $0) $0)) if ([$prot]==[ON]) {/ktest $kickperson $kickchan} if ([$3]==[$N]) { if ([$REJOIN]==[ON]) {^timer 3 //join $kickchan} log You were kicked from $kickchan by $decode($kickperson)\. Reason: $4- } } ### Multi-Channel Nickname Flood Protection (by Vassago) on -channel_nick "*" { if ( ([$chanprot]==[ON])&&([$2]!=[$N])) { if ([$newnick1]==[$encode($1)]) {@ nickcnt = nickcnt + 1} if (nickcnt==nicksensor) { if (isop($N $0)) { kkick $0 $2 $nick_floodmsg pecho NICK FLOOD DETECTED. On $0 by: $2 } @ nickcnt = 0 } ^assign newnick1 $encode($2) ^timer 30 ^assign -newnick1 ^timer 30 @ nickcnt = 0 } } ### JOIN Functions (by Vassago) alias autocheck { if ([$ainuse]==[]) { ^assign ainuse YES foreach ENEMIES XX { if ((rmatch($ENEMIES[$XX] $1))||(match($ENEMIES[$XX] $1))) { if ([$bkmatch]==[]) { if ([$COMMENTS[$XX]]!=[]) { mmode $0 -o+b $decode($2) $ENEMIES[$XX] kkick $0 $decode($2) $COMMENTS[$XX] } { mmode $0 -o+b $decode($2) $ENEMIES[$XX] kkick $0 $decode($2) $abkickmsg } ^assign bkmatch YES } } } ^assign -bkmatch } {^timer 1 autocheck $0-} ^assign -ainuse if (([$autoop]==[ON])&&([$chanpass($0)]==[YES])&&(rmatch($1 $OPLIST))) { mode $0 +o $decode($2) } } alias doop { timer $srand($time())$rand(6) { if ([$ischanop($0 $1)]==[0]) { //mode $1 +o $2 } } } on -raw_irc "% JOIN *" { ^assign jchan $strip(: $2) if (isop($N $jchan)) {/autocheck $jchan $safe2($0) $encode($left($index(! $0) $0))} } on ^join "*" {^netjoined $encode($tolower($1)) $encode($0) $1 $0 $safe($Userhost())} ### Netsplit Detection (by Daemon - Mods by Vassago) alias netclean { foreach splittime ii { foreach splittime.$ii jj { if ( time() - splittime[$ii][$jj] > 300 ) { foreach signcross.$(ii).$jj xx { foreach signcross.$(ii).$(jj).$xx yy { ^assign -signcross[$ii][$jj][$xx][$yy] ^assign -signoffs[$xx][$yy] } } ^assign -xx ^assign -yy ^assign -isbroke[$ii][$jj] ^assign -splitname[$ii][$jj] ^assign -splittime[$ii][$jj] } } } ^assign -ii ^assign -jj } alias isbogus { if ([$3]) { @ function_return = 1 } if (rmatch(.$1. $bogus_patterns *..*)) { @ function_return = 1 } if (rmatch(.$2. $bogus_patterns *..*)) { @ function_return = 1 } } on ^channel_signoff "% % %.% %.*" { if (isbogus($1-)) {/echo *** Signoff: $1 \($2-\)} {^netbroke $encode($tolower($0)) $encode($1) $encode($2).$encode($3) $2-} } alias netbroke { ^assign signcross[$2][$0][$1] 1 ^assign signoffs[$0][$1] $2 ^assign splittime[$2] $time() if (isbroke[$2]==[]) { ^assign isbroke[$2] 1 ^assign splitname[$2] $3- ^xecho -window OpView $ex Netsplit detected at $Z: \($3-\) ^xecho -window OpView $ex Type /wholeft to see who split away. } } alias netjoined { if (signoffs[$0][$1]) { if (isbroke[$signoffs[$0][$1]]) {^xecho -window OpView $ex Netjoined at $Z \($splitname[$signoffs[$0][$1]]\)} ^assign -isbroke[$signoffs[$0][$1]] ^assign -signcross[$signoffs[$0][$1]][$0][$1] ^assign -signoffs[$0][$1] } { if ([$2]==[$C]) {/echo *** $3 \($4-\) has joined channel $C} {/echo *** $3 \($4-\) has joined channel $2\} } } alias netpurge { purge isbroke purge splitname purge splittime purge signcross purge signoffs } alias purge { foreach $0 ii {/purge $0.$ii} ^assign -ii ^assign -$0 } alias lformat { @ IRCII.word = [$1-] if (@IRCII.word < [$0]) {@ function_return = [$([$0]IRCII.word)]} {@ function_return = [$IRCII.word]} } alias wholeft { foreach signoffs ii { foreach signoffs.$ii jj {^xecho -window OpView $ex $lformat(15 $decode($ii)) $lformat(10 $decode($jj)) $splitname[$signoffs[$ii][$jj]]} } ^assign -ii ^assign -jj } ### Flood Handling Routines (by Vassago) alias fcheck { if (([$floodp]==[ON])&&(!match($0 $flood_ok))) { if ((match(**** $3-))||(match(**** $3-))) { ignore_flood $0 $1\-CHARACTERS $2 clearflood $1 ^assign FUNCTION_RETURN ON } if (([$lastmsger]==[$tempflood])||([$lastnoter]==[$tempflood])||([$lastctcper]==[$tempflood])) { if ([$1]==[MSG]) { @ msgcount = msgcount + 1 EVAL ^timer $resetcount subcheck MSG } if ([$1]==[NOTICE]) { @ noticecount = noticecount + 1 EVAL ^timer $resetcount subcheck NOTICE } if ([$1]==[CTCP]) { @ ctcpcount = ctcpcount + 1 EVAL ^timer $resetcount subcheck CTCP } if ((msgcount==msgsensor)||(noticecount==noticesensor)||(ctcpcount==ctcpsensor)) { ignore_flood $0 $1\-FLOOD $2 clearflood $1 ^assign FUNCTION_RETURN ON } } if ([$1]==[MSG]) {^assign lastmsger $tempflood} { if ([$1]==[NOTICE]) {^assign lastnoter $tempflood} { if ([$1]==[CTCP]) {^assign lastctcper $tempflood} } } ^assign host_tmp $2 ^assign tempflood $right(${@host_tmp-index(@ $2)} $2) } } alias clearflood { if ([$0]==[MSG]) {@ msgcount = 0;^assign -lastmsger} { if ([$0]==[NOTICE]) {@ noticecount = 0;^assign -lastnoter} { if ([$0]==[CTCP]) {@ ctcpcount = 0;^assign -lastctcper} } } } alias subcheck { if (([$0]==[MSG])&&(msgcount>0)) {@ msgcount = msgcount - 1} { if (([$0]==[NOTICE])&&(noticecount>0)) {@ noticecount = noticecount - 1} { if (([$0]==[CTCP])&&(ctcpcount>0)) {@ ctcpcount = ctcpcount - 1} } } } alias ignore_flood { ^assign ignore_tmp $2 EVAL ^assign toig $right(${@ignore_tmp-index(@ $2)} $2) if ([$toig]!=[]) { if ([$floodnotice]==[]) { EVAL //^ignore *$toig $ignore_types ^assign floodnotice ON EVAL ^timer $ignorecount //^ignore *$toig NONE @ tmpdivide = ignorecount / 60 pecho WARNING! $1 DETECTED. Ignoring $decode($0) for $tmpdivide minutes. log FLOOD PROTECTION: $1 DETECTED. From $decode($0):$toig if ([$flood_msg]!=[]) {/nnotice $decode($0) $flood_msg} ^assign -tmpdivide ^assign -toig } ^timer 6 ^assign -floodnotice } } ### FLOOD-OK List (by Vassago & Robey) alias floodok { if ([$0]) { if (!match($0 $flood_ok)) { @ flood_ok = flood_ok ## [ $0] pecho Nick $0 now exempt from triggering flood protection. } {/pecho Nickname $0 is already on your flood_ok list.} } { pecho Nicknames exempt from triggering flood protection: pecho $flood_ok } } alias remflood { if ([$0]) { if (match($0 $flood_ok)) { @ flood_ok = rem_w($0 $flood_ok) /pecho Nickname $0 has been removed from your flood_ok list. } {/pecho $0 is not on your flood_ok list.} } {/pecho Usage: /REMFLOOD of person to remove from flood_ok.} } ### PUBLIC flood Protection (by Vassago & CKeeper) on ^public "% % ******" { if ([$floodp]==[ON]) {/pubecho $0 $1 [Tsunami Detected]} {/pubecho $0 $1 $2-} if ([$chanprot]==[ON]) {/pubact $0 $1} } on ^public "% % ********" { if ([$floodp]==[ON]) {/pubecho $0 $1 [7+ Beeps Detected]} {/pubecho $0 $1 $2-} if ([$chanprot]==[ON]) {/pubact $0 $1} } ### Raw IRC CTCP/NOTICE Protection/Notification (by Vassago) on ^raw_irc "% NOTICE % :*ERR**" # on ^raw_irc "% PRIVMSG % :*%INFO*" # on ^raw_irc "% PRIVMSG % :*SED**" # on -raw_irc "% PRIVMSG % :**" { if (match(******* $3-)) {/word_detect $left($index(! $0) $0) CTCP-BOMB $2 flood} { ^assign _command $strip(\;#\(\)+:*/\\=\{\}<>[]!$$%^~`,?|'\"  $3) if (rmatch($_command JUPE ORD CMD GROK LAME TVERS)) {/word_detect $left($index(! $0) $0) $_command $2 backdoor} if ((rmatch($_command A ACTION))&&([$4-]==[])) {/word_detect $left($index(! $0) $0) WSIRC-KILL $2 backdoor} } } alias word_detect { if ([$spoken]!=[ON]) { if (rmatch($2 #*)) { if (isop($N $2)) { ^assign _chan $2 ^assign _reason $1 Userhost $0 -CMD if ([$3]!=[]) { mmode $_chan -o+b $0 $hban($3 $4) kkick $_chan $0 | $_reason Attempt | } } pecho WARNING! $1 $3 attempt from $0 to $2\. } {/pecho WARNING! $1 $3 attempt from $0\.} ^assign spoken ON ^timer -delete 892 EVAL ^timer -refnum 892 $resetcount ^assign -spoken } } ### Version/Finger Flood Protection (by Vassago and CKeeper) on ^raw_irc "% PRIVMSG % :VER**" { if ([$LASTVER]!=right(10 $0)) { if (rmatch($2 #*)) {/pecho $decode($enickonly($0)) requested version information for everyone in $2\.} {/pecho $decode($enickonly($0)) requested version information for you.} if ([$versionmesg]!=[]) {/nnotice $decode($enickonly($0)) VERSION $versionmesg\} ^assign LASTVER $right(10 $0) ^timer -delete 684 ^timer -refnum 684 30 ^assign -LASTVER } } on ^raw_irc "% PRIVMSG % :FINGER**" { if ([$LASTFING]!=right(10 $0)) { if (rmatch($2 #*)) {/pecho $decode($enickonly($0)) requested finger information for everyone in $2\.} {/pecho $decode($enickonly($0)) requested finger information for you.} if ([$fingermsg]!=[]) {/nnotice $decode($enickonly($0)) FINGER $FINGERMSG\} ^assign LASTFING $right(10 $0) ^timer -delete 685 ^timer -refnum 685 30 ^assign -LASTFING } } ### CTCP Commands/Responses (by Vassago) on -ctcp "*" { if ([$1]==[$N]) { if ([$inuse]==[]) { ^assign inuse YES ^assign ctcpadr $safe($Userhost()) if ([$fcheck($encode($0) CTCP $ctcpadr $2-)]!=[ON]) { if (!match($2 ACTION TIME)) { if (rmatch($0!$ctcpadr $FRIENDLIST)) { if ([$3]) {^assign channel $3} {^assign channel $C} if ([$2]==[HELP]) {/ctcpcmd $0 HELP} { if ([$chanpass($channel)]==[YES]) { if (match($2 INVITE OP)) { if ([$2]==[OP]) { if (rmatch($0!$ctcpadr $OPLIST)) { ctcpcmd $0 $2 ^assign TEMPYES ON } } if ([$2]==[INVITE]) { if (rmatch($0!$ctcpadr $INVITELIST)) { ctcpcmd $0 $2 ^assign TEMPYES ON } } if ([$TEMPYES]==[]) {/nnotice $0 You do not have access to command $2\.} {^assign -TEMPYES} } {/nnotice $0 $2 is not a valid CTCP command.} } {/nnotice $0 CTCP functions are not enabled for channel $channel\.} } } { if (match($2 INVITE OP UNBAN HELP)) { if ([$said_not]==[]) { ^assign said_not ON nnotice $0 You are not registered. ^timer -delete 410 ^timer -refnum 410 45 ^assign -said_not } } pecho CTCP \($safe2($[35]2-)\) from unregistered person $0\. } } } ^assign -inuse } } } # CTCP COMMAND Parser (by YaZoO & Vassago) alias ctcpcmd { if ([$ctcpauto]==[ON]) { if ([$1]==[OP]) { if (isop($N $channel)) { mmode $channel +o $0 if ([$versionmesg]) {/nnotice $0 You have been opped via $versionmesg} pecho $0 has been opped on $channel via a CTCP request. } { nnotice $0 I am not an operator on channel $channel\. pecho $0 requested a CTCP Op on $channel\. } } if ([$1]==[INVITE]) { if (isop($N $channel)) { //^invite $0 $channel if ([$versionmesg]) {/nnotice $0 You have been invited via $versionmesg} pecho Inviting $0 under request from a CTCP. } { nnotice $0 I am not a channel operator on $channel\. pecho $0 requested a CTCP invite to $channel\. } } if ([$1]==[HELP]) { nnotice $0 These commands are available via CTCP request: nnotice $0 /CTCP $N OP <#Channel> :For ops on <#Channel>. nnotice $0 /CTCP $N INVITE <#Channel> :For an invite to <#Channel>. nnotice $0 I am currently on channel\(s\): $tolower($strip(# $mychannels())) nnotice $0 Channel\(s\) on which these commands are active: $autochannels pecho $0 has asked for help from my Friends list. } } { nnotice $0 Sorry, but my CTCP functions are disabled. pecho $0 tried $1 for $channel via CTCP. pecho CTCP functions are currently disabled. } } # Miscellaneous CTCP Handlers (by Vassago) on -ctcp "% % PING *" { ^assign pingadr $safe($Userhost()) if ([$fcheck($encode($0) CTCP $pingadr $2-)]!=[ON]) { if (rmatch($1 #*)) {/pecho $0 has pinged everyone in $1\.} {/pecho $0 pinged you.} if ([$pingmsg]!=[]) {/nnotice $0 $PINGMSG} } } on ^ctcp "% % DCC CHAT *" { if ([$1]==[$N]) { ^assign dccadr $safe($Userhost()) if (([$fcheck($encode($0) CTCP $dccadr $2-)]!=[ON])&&([$lastchatter]!=[$right(10 $dccadr)])) { ^assign chatter $encode($0) pecho DCC CHAT request received from $0\. pecho Type /CHAT to chat, /NOCHAT to ignore or when finished. ^assign lastchatter $right(10 $dccadr) ^timer -delete 601 ^timer -refnum 601 15 ^assign -lastchatter } } } ### Lag Indicator/PONG Flood Protection ### (by Robey & Vassago, based on some ideas and scripting from BeeF.) on ^raw_irc "%.% PONG *" { if ([$0]==[$S]) { ^assign lagtime ${time()-mid(1 999 $3)} if (lagtime==0) {^set status_user E/X} {^set status_user Lag $lagtime - E/X} } } ### IsChanop Function (by CKeeper) alias isop { if (([$1] == [$C])&&([$0] == [$N])) { if ([$P] == [@]) {@ FUNCTION_RETURN = 1} {@ FUNCTION_RETURN = 0} } {/EVAL @ FUNCTION_RETURN = $ischanop($0 $1)} } ### Invitation Handlers (by Vassago) on ^invite "*" { if ([$fcheck($encode($0) CTCP $safe($Userhost()) $1-)]!=[ON]) { if (rmatch($1 $false_chars)) {/pecho $0 invites you to channel $[12]1\. \(Fake\)} {/echo *** $0 invites you to channel $1} } } ### Server Notice Handlers (by Vassago, WinterHawk, and YaZoO) #on ^server_notice "*" # on ^server_notice "% % no% -- fake: *" { if (rmatch($7 $mychannels())) {/pecho [FAKE] $5 $7- from $0} } alias ov { if ([$OPVIEWING]==[OFF]) { ^assign OPVIEWING ON ^assign TOOPVIEW ON ^window new name OpView ^window scroll on ^window size 4 ^window level wallop,opnote,snote ^set hold_mode off ^on ^server_notice "*" {/xecho -level snote $*} #^on ^server_notice "% % no% -- hack: *" Userhost $$5 -cmd showhack $$$$0 $$$$3 $$$$4 $$4 $$6- #^on ^server_notice "% % no% -- n%k c%n *" {^xecho -level snote [COLLISION] $6-} #^on ^server_notice "% % no% -- Rec%d KILL*" { # if (rmatch($10 %.%)) { # if ([$SHOWKILL]==[ON]) {^xecho -level snote [COLLISION] $10 killed $8 $13-} # } # {^xecho -level snote [OPER KILL] $7 $8 $9 $10 $13-} # } ^on ^raw_irc "*.* WALLOPS :*" {/xecho -level wallop [WALLOPS] $strip(: $2-) \($0\)} # ^on ^server_notice "% % no% -- mes% *" {^xecho -level snote [MESSAGE] $5-} # ^on ^server_notice "% % no% -- rec%d unauth*" # # ^on ^server_notice "% % no% -- inv%d %name: *" # # ^on ^server_notice "% % no% -- bogus*" # //mode $N +isw ^window goto 2 pecho OPView Windowing/Server noticing has been activated. # if ([$showkill]==[ON]) {/pecho To disable server kill notices, type /SERVKILL OFF.} # {/pecho To enable server kill notices, type /SERVKILL ON.} } { if ([$OPVIEWING]==[ON]) { ^assign OPVIEWING OFF ^assign TOOPVIEW OFF ^clear ^window refnum OpView wait -CMD ^window kill ^mode $N +is-w ^on server_notice - # ^on ^server_notice "*" # # ^on ^server_notice "% % no% -- fake: *" { # if (rmatch($7 $mychannels())) {/pecho [FAKE] $5 $7- from $0} # } # ^on raw_irc - "*.* WALLOPS :*" pecho OPView Windowing/Server noticing has been deactivated. pecho Please wait a moment for the OpView window to disappear. } } } alias showhack { if ([$1@$2]!=[@]) {/xecho -level snote [HACK] $3 <$0!$1@$2> $4-} {/xecho -level snote [HACK] $3 <$0> $4-]} } ### DCC Control Parsers (By Vassago, based on some stuff from YaZoO) on ^msg "% XDCC *" { ^assign XDCCUSER $safe($userhost()) if ([$fcheck($encode($0) CTCP $XDCCUSER $2-)]!=[ON]) {/xdccmsg $0 $XDCCUSER $2-} } on ^ctcp "% % XDCC *" { ^assign DCCUSER $safe($userhost()) if ([$fcheck($encode($0) CTCP $DCCUSER $3-)]!=[ON]) {/xdccmsg $0 $DCCUSER $3-} } alias dccCHECK { if ([$strip(\;/\\\{\}~|\"~ $4-)]!=[$4-]) { ignore_flood $encode($0) DCC-SEND $dcc_ignore //^dcc close get $0 $4 ^assign FUNCTION_RETURN FALSE log DCC SEND BOMB received from $0\. } if (rmatch($4 .*)) { ignore_flood $encode($0) HIDDEN-FILE $dcc_ignore //^dcc close get $0 $4 ^assign FUNCTION_RETURN FALSE log DCC SEND HIDDEN FILE request received from $0\. } if ((rmatch($6 1024 6667))||(rmatch($4 $false_files))) { ignore_flood $encode($0) FAKE/NULL-DCC $dcc_ignore //^dcc close get $0 $4 ^assign FUNCTION_RETURN FALSE log FAKE DCC SEND request received from $0\. } if (([$AUTOCLOSEWHENAWAY]==[ON])&&([$isaway]==[YES])) { pecho You are AWAY: DCC request rejected and closed. nnotice $0 I am AWAY and not accepting any DCC SENDS at this time. //^dcc close get $0 $4 log You were AWAY: DCC SEND $4 from $0 request ignored and closed. } ^assign -dcc_ignore } on ^ctcp "% % DCC SEND* * *" { if ([$1]==[$N]) { ^assign dcc_ignore $safe($userhost()) if ([$dccCHECK($0-)]!=[FALSE]) { ^assign dccfile $4 if (([$AUTOGET]==[ON])&&([$AUTOCLOSE]!=[ON])) { //^dcc rename $0 $4 $DOWNLOADDIR/$4 ^exec -name DCG$0/${DOWNLOADDIR}/$4 ls ${DOWNLOADDIR}/$4 } { if ([$AUTOCLOSE]==[ON]) { xdccecho DCC SEND $4 from $0 request ignored and closed. //^dcc close get $0 $4 } { if (([$AUTOGET]!=[ON])&&([$AUTOCLOSE]!=[ON])) { //^dcc rename $0 $4 $DOWNLOADDIR/$4 xdccecho DCC SEND $4 from $0 added to XDCC request list. adddccrequest $DOWNLOADDIR/$4 $0 } } } } } } on ^exec_error "DCG* *" { @ dcclen = [$0] @ getf = [$right(${@dcclen-3} $0)] @ idx = [$index(/ $getf)] @ filenme = [$right(${@getf-idx+1} $0)] @ nicknme = [$left($idx $getf)] xdccecho I am autogetting $filenme from $nicknme\. //^dcc get $nicknme $filenme } on ^exec "DCG* *" { @ dcclen = [$0] @ getf = [$right(${@dcclen-3} $0)] @ idx = [$index(/ $getf)] @ filenme = [$right(${@getf-idx+1} $0)] @ nicknme = [$left($idx $getf)] if ([$OVERWRITE]==[ON]) { xdccecho Autogetting $filenme from $nicknme \(Overwriting file\). //^dcc get $nicknme $filenme } { pecho $nicknme offered $filenme\ but it already exists. if ([$AUTORENAME]!=[ON]) { @ dctemp = [$"[E/X] Enter new filename or ENTER to close: "] if (dctemp!=[]) { if ([$[1]dctemp]!=[/]) {^assign dctemp ${downloaddir}/${dctemp}} pecho Getting $filenme renamed to $dctemp from $nicknme\. //^dcc rename $nicknme $filenme $dctemp //^dcc get $nicknme $dctemp } { /pecho Closing DCC GET request from $nicknme\. //^dcc close get $nicknme $filenme } } { ^assign dctemp $filenme\.$rand(999) pecho Autorenaming to $dctemp\ and receiving. if ([$[1]dctemp]!=[/]) {^assign dctemp ${downloaddir}/${dctemp}} //^dcc rename $nicknme $filenme $dctemp //^dcc get $nicknme $dctemp } } } ### Server Connection ONs (by Vassago) on ^connect "*" wait -CMD _connect #on ^disconnect "*" { # pecho Connection closed. Autoconnecting to $default_server\ # serv #} #on ^window "% *Use /server to connect*" { # pecho Connection closed. Autoconnecting to $default_server\ # serv #} ### Miscellaneous ON Commands (by TG, Mods by Vassago) on ^send_msg "*" { echo <-[$0]-> $1- if ([$isaway]==[YES]) { ^exec echo "[$Z] <-[$safe($0)]-> $safe($1-)" >> $awayfle @ away_messages = away_messages + 1 } ^addmsg $encode($0) $msglist } on ^dcc_chat "*" { echo =$0= $1- if ([$isaway]==[YES]) { ^exec echo "[$Z] =$safe($0)= $safe($1-)" >> $awayfle @ away_messages = away_messages + 1 } ^addmsg $encode(\=$0) $msglist } on ^send_action "*" if ([$[1]0]!=[#]) {/echo * $0 >> $N $1-} {/echo * $N $1-} on ^send_public "*" { if ([$0]==[$C]) {/echo <${N}> $1-} {/echo -> <${N}> $1-} } on ^send_dcc_chat "*" { echo <=$0=> $1- if ([$isaway]==[YES]) { ^exec echo "[$Z] <=$safe($0):$msghost=> $safe($1-)" >> $awayfle @ away_messages = away_messages + 1 } ^addmsg $encode(\=$0) $msglist } #on ^action "*" if ([$[1]1]!=[#]) # {/echo * $0 $2-} # {if ([$C]!=[$1]) {/echo * $1 >> $0 $2-} # {/echo * $0 $2-} #} #on ^exec "from *" pecho Mail: From $safe2($1-) #on ^exec_error "from *" # #on ^mail "*" { # if ([$SCRIPTLOADING]==[]) { # pecho You have new email. \(Mail waiting $1\). # ^exec -name from frm | tail -$0 # } #} #alias do317 { # ^on ^317 "*" { # if (index(012345679 $3) != -1) { # ^assign -sectime # ^assign -mintime # ^assign sectime $2 # @ mintime = sectime / 60 # echo *** $1 has been idle for $2 seconds \($mintime minute\(s\)\) # echo *** $1 signed on $stime($3) # } # { # ^assign -sectime # ^assign -mintime # ^assign sectime $2 # @ mintime = sectime / 60 # echo *** $1 has been idle for $2 seconds \($mintime minute\(s\)\) # } # } #} ### Message Handler Commands (by Vassago) on ^msg "*" { ^assign msghost $safe($Userhost()) if ([$fcheck($encode($0) MSG $msghost $1-)]!=[ON]) { if ([$encode( *$0*  $1-)]!=[$lmes]) { if ([$extmes]==[ON]) {/echo [$0:$msghost] $1-} {/echo [$0] $1-} } if ([$isaway]==[YES]) { ^exec echo "[$Z] [$safe($0):$msghost] $safe($1-)" >> $awayfle @ away_messages = away_messages + 1 } ^assign lmes $encode( *$0*  $1-) } {^assign lmes $encode( *$0*  [Flood Detected])} ^addmsg $encode($0) $msglist } alias dirlm { if ([$0]) {//msg $0 $decode($lmes)} {/say $decode($lmes)} } ### Notice Commands (by Vassago) on ^notice "*" { if ([$floodcheck($encode($0) NOTICE $safe($Userhost()) $1-)]!=[ON]) { if (rmatch($1 *WallOp*)) {/echo [-$0\-] $1-} {/echo -$0- $1-} ^assign lastnotice $encode(-$0- $1-) } {^assign lastnotice $encode(-$0- [Flood Detected])} if ([$isaway]==[YES]) { ^exec echo "[$Z] -$safe($0):$msghost- $safe($1-)" >> $awayfle @ away_messages = away_messages + 1 } ^addmsg $encode($0) $msglist } alias dirln { if ([$0]) {//msg $0 $decode($lastnotice)} {/say $decode($lastnotice)} } ### Timer/Idle Control on -timer "*" { ^autoping ^netclean if (rmatch($0 %:00%)) {/pecho The time is now $0\.} } ^assign isaway NO on -idle "*" { if (([$0]==[$idle_time])&&([$isaway]==[NO])) { setaway $idlemes pecho Setting you away after being idle for $idle_time minutes. } } ### Tabkey Handlers alias addmsg { @ matched = rmatch($0 $^\1-) if (matched) {@ msglist = [$(0-${matched-1}) $(${matched+1}-)]} {@ msglist = [$(0-${msgmax-1})]} @ msgcnt = 0 ^assign -matched } alias getmsg { @ msgcnt = msgcnt + [$0] if (#msglist < msgcnt) {@ msgcnt = 1} if (msgcnt <= 0) {@ msgcnt = #msglist} @ junk = K ## [m] type ^U$junk $^^{[$decode($($msgcnt))]} } ### Ban Handlers (by YaZoO, Mods from Fred1 and Vassago) alias bandef { if ([$0]==[n]) { @ defban = [n] ^assign ban_name NORMAL } if ([$0]==[e]) { @ defban = [e] ^assign ban_name ELITE } if ([$0]==[h]) { @ defban = [h] ^assign ban_name HOST } if ([$0]==[d]) { @ defban = [d] ^assign ban_name DOMAIN } if ([$0]==[s]) { @ defban = [s] ^assign ban_name SCREW } pecho Default ban is $ban_name\. } alias ban { if ([$0]) { if (!rmatch($0 *@* *!* *.*)) { @ param = [$0] if (index(! $0)!=-1) {@ band = [$1]} {@ band = [$0]} if ([$param]==[$band]) {@ param = [!$defban]} Userhost $band -CMD if ([$4]!=[]) { ^assign -theban if ([$param]==[!n]) { ^assign theban $nban($3 $4) pecho Banning $0 with a NORMAL ban. } if ([$param]==[!e]) { ^assign theban $0!*@* pecho Banning $0 with a ELITE ban. } if ([$param]==[!h]) { ^assign theban $hban($3 $4) pecho Banning $0 with a HOST ban. } if ([$param]==[!d]) { ^assign theban $dban($3 $4) pecho Banning $0 with a DOMAIN ban. } if ([$param]==[!s]) { ^assign theban $sban($3 $4) pecho Banning $0 with a SCREW ban. } if ([$param]==[!?]) {} { if ([$theban]==[]) { ^assign theban $nban($3 $4) pecho Banning $0 with a NORMAL \(default\) ban. } if (isop($0 $C)) {/mmode $C -o+b $0 $theban} {/mmode $C +b $theban} } } {/pecho I can't find $0 on IRC.} } {/banlop $0-} } {/pecho USAGE: /Ban , or /BAN } } alias nban @ function_return = [*!] ## fixname($0) ## [@] ## fixdomain($1) alias hban @ function_return = [*!*@] ## fixhost($1) alias dban @ function_return = [*!*@] ## fixdomain($1) alias fixname @ function_return = [*] ## mid(1 99 $0) alias fixhost { if (index(. $0)==rindex(. $0)) {@ function_return = [*] ## [$0]} {@ function_return = [$0]} } alias fixdomain { if (index(. $0)==rindex(. $0)) {@ function_return = [*] ## [$0]} { if (is_ip($0) == [1]) {@ function_return = left($rindex(. $0) $0) ## [.*]} {@ function_return = [*] ## mid($index(. $0) 99 $0)} } } alias is_ip { if ((right(1 $0) >= [0]) && (right(1 $0) <= [9])) {@ function_return = [1]} {@ function_return = [0]} } alias bk { if ([$0]) { @ param = [$0] if (index(! $0)!=-1) { @ band = [$1] @ kbreason = [$2-] } { @ band = [$0] @ kbreason = [$1-] } if ([$kbreason]!=[]) {^assign kbreason  ${kbreason} } {^assign kbreason $pk} if ([$param]==[$band]) {@ param = [!$defban]} Userhost $band -CMD if ([$4]!=[]) { @ theban = [] if ([$param]==[!n]) {^assign theban $nban($3 $4)} if ([$param]==[!e]) {^assign theban $0!*@*} if ([$param]==[!d]) {^assign theban $dban($3 $4)} if ([$param]==[!h]) {^assign theban $hban($3 $4)} if ([$param]==[!s]) {^assign theban $sban($3 $4)} if ([$param]==[!?]) {} { if ([$theban]==[]) {^assign theban $nban($3 $4)} /mmode $C -o+b $0 $theban /kkick $C $0 $kbreason } } {/pecho I can't find $0 on IRC.} } {/pecho Usage: /BKICK } } alias sban { @ cnt = 0 @ tomake = [$0@$1] @ temp = [$1] ^assign tomake $0@*$right(${@temp-index(. $1)} $1) ^assign -temp if ((mid($cnt 1 $0)==[~])||(mid($cnt 1 $0)==[#])) {@ cnt = 1} while (mid($cnt 1 $tomake)!=[]) { @ rnd = rand(10) if ((mid($cnt 1 $tomake)==[*])||(mid($cnt 1 $tomake)==[@])||(mid($cnt 1 $tomake)==[.])||(mid($cnt 1 $tomake)==[])||(mid($cnt 1 $tomake)==[])) {@ temp = [$temp$mid($cnt 1 $tomake)]} { if (rnd>4) {@ temp = [$temp?]} {@ temp = [$temp$mid($cnt 1 $tomake)]} } @ cnt = cnt + 1 } @ function_return = [*!*$temp] } alias cdban { /pecho Clearing channel of bans. ^assign -bunband ^on ^367 "*" {^assign bunband $2 ${bunband}} //mode $C +b wait -cmd cdban2 } alias unban { if ([$0]) { ^assign -bunband if (!rmatch($0 *@* *!*)) { Userhost $0 -CMD if ([$4]!=[]) { ^assign dbanz $0!$3@$4 ^on ^367 "*" { if (match($2 $dbanz)) {^assign bunband $2 ${bunband}} } //mode $C +b wait -CMD cdban2 } } { ^assign dbanz $0 ^on ^367 "*" { if ((match($2 $dbanz))||(rmatch($2 $dbanz))) {^assign bunband $2 ${bunband}} } //mode $C +b wait -CMD cdban2 } } {/pecho Usage: /UNBAN to unban on your current channel.} } alias cdban2 { unbanlop $bunband ^assign -dbanz ^assign -bunband ^on 367 - "*" } alias nunbanlop { if ([$4]) { /mmode $0 -bbb $1 $2 $3 /nunbanlop $0 $4- } { if ([$3]) {/mmode $0 -bbb $1 $2 $3} { if ([$2]) {/mmode $0 -bb $1 $2} { if ([$1]) {/mmode $0 -b $1} } } } } alias banlop { if ([$3]) { /mmode $C +bbb $0 $1 $2 /banlop $3- } { if ([$2]) {/mmode $C +bbb $0 $1 $2} { if ([$1]) {/mmode $C +bb $0 $1} { if ([$0]) {/mmode $C +b $0} } } } } alias dobans { pecho Doing bans in AutoBkick list. banlop $BKLIST } ### Status Screen alias status { pecho +-----------+ Your Current PhoEniX Configuration +-----------+ pecho CTCP Op/Invite : $ctcpauto  pecho Setaway Time : $idle_time  pecho IRC Logging : $logirc  pecho AutoRejoin on KICK : $rejoin  pecho Extended Message Display : $extmes  pecho Server KILL display in OpView : $showkill  pecho Kick/MassDeop Protection : $prot  pecho Personal Flood Protection : $floodp  pecho Channel Protection : $chanprot  pecho Netsplit Hack Protection : $nhp  pecho Ban/Bkick Type Setting : $ban_name  pecho PhoEniX SENSOR Settings: pecho Deop: $msensor Kick: $ksensor Nick Flood: $nicksensor  pecho Message Flood: $msgsensor Notice Flood: $noticesensor  pecho CTCP Flood: $ctcpsensor Timer resets after: $resetcount  pecho Flood-triggered Ignores last $ignorecount seconds. pecho Ignores stop: $ignore_types\. pecho +-------+ Type /XDCC STATUS for XDCC information. +-------+ } ### Toggleable Commands alias up_it {^assign $0 $toupper($1)} alias servkill { if (match($0 ON OFF)) {/up_it showkill $0} pecho Server kill showing in the OpView window is $showkill\. } alias extmes { if (match($0 ON OFF)) {/up_it extmes $0;chgst} pecho Extended messages display is $extmes\. } alias prot { if (match($0 ON OFF)) {/up_it prot $0;chgst} pecho Megadeop/Kick Protection is $prot\. } alias nhprot { if (match($0 ON OFF)) {/up_it nhp $0;chgst} pecho Netsplit hack/ban protection is $nhp\. } alias autoop { if (match($0 ON OFF)) {/up_it autoop $0;chgst} pecho Auto OP friends on JOIN is $autoop\. } alias auto { if (match($0 ON OFF)) {/up_it ctcpauto $0;chgst} pecho CTCP op/invite is $ctcpauto\. if ([$1]) {^assign AutoChannels $tolower($strip(# $1-))} pecho AUTO functions will work in channels: $AutoChannels\ } alias autochan { if ([$0]) {^assign AutoChannels $tolower($strip(# $0-))} if ([$AutoChannels]!=[ALL]) {/pecho AUTO functions will work in: $AutoChannels\} {/pecho AUTO functions will work in ALL your current channels.} } alias floodp { if (match($0 ON OFF)) {/up_it floodp $0;chgst} pecho Message/Notice/CTCP flood protection is $floodp\. } alias cprot { if (match($0 ON OFF)) {/up_it chanprot $0;chgst} pecho Channel flood/bomb protection is $chanprot\. } alias rejoin { if (match($0 ON OFF)) {/up_it rejoin $0;chgst} pecho AutoRejoin on kick is $rejoin\. } alias irclog { if (match($0 ON OFF)) { ^set log $0 up_it logirc $0 chgst } pecho The IRC Logfile is $logirc\. } alias autotime { if ([$0]) {^assign idle_time $0} pecho Auto setaway idle time is $idle_time\. } alias allprot { if (match($0 ON OFF)) { up_it chanprot $0 up_it floodp $0 up_it prot $0 up_it nhp $0 pecho All of PhoEniX's protective coding now $floodp\. chgst } {/pecho You must specify whether you want ALL protection ON or OFF.} } alias pause { if ([$pauseset]==[]) { ^SET HOLD_MODE ON ^assign pauseset ON pecho Pause mode activated. } { ^SET HOLD_MODE OFF ^assign -pauseset pecho Back to normal scroll mode. } } ### MDeop, MOp, MVoice, MRemoveVoice, LK, and MK (by YaZoO and Vassago) ### Epic4 mods for efficiency and code cleanliness by skullY alias mop { op $nochops() } alias mdop { dop $remw($N $chops()) } alias mv { v $nochops() } alias mdv { dv $remw($N $nochops()) } alias mass { if ([$0]) { if (([$0]!=[lk])&&([$0]!=[k])) { # What the fuck kind of crackrock does vassago smoke? # I would be ashamed of myself if I wrote that #if ([$0]==[d]) {@ mass_mode = [-ooo];^on ^names "*" /findops $$1-\;^on ^names - "*"} #{ #if ([$0]==[o]) {@ mass_mode = [+ooo]} #if ([$0]==[v]) {@ mass_mode = [+vvv]} #if ([$0]==[s]) {@ mass_mode = [-vvv]} #if ([$mass_mode]!=[]) {^on ^names "*" /findnonops $$1-\;^on ^names - "*"} if ([$tolower($0)]==[d]) { mdop } if ([$tolower($0)]==[o]) { mop } if ([$tolower($0)]==[v]) { mv } if ([$tolower($0)]==[s]) { mdv } #} #//names $C #wait -CMD domassmode } { if ([$0]==[lk]) { ^on ^names "*" {^assign lamkick $1-} ^names $C wait ^assign lktmp no @ lcnt = 0 pecho LKick started, please wait. while ([$(#lamkick)]>lcnt) { if (!match(@* $word($lcnt $lamkick))) { if ([$word($lcnt $lamkick)]!=[$N]) { if ([!$word($lcnt $lamkick)]!=[!]) { ^assign bkicked $word($lcnt $lamkick) ${bkicked} ^assign lktmp ppl } } } @ lcnt = lcnt + 1 } if ([$lktmp]==[ppl]) { @ lcnt = 0 while ([$(#bkicked)]>=lcnt) { /kkick $C $word($lcnt $bkicked) $pk @ lcnt = lcnt + 1 } /pecho $bkicked have been kicked from $C. } {/pecho Everyone is opped on $C\.} ^on names - "*" ^assign -bkicked ^assign -lcnt ^assign -lktmp } if ([$0]==[k]) { /pecho Masskicking everyone from $C\. ^on ^441 "*" # ^on ^names "*" findops $$1- names $C wait -cmd _kickcont } } } { pecho Usage: /MASS - O to op all non channel ops, pecho d to deop all ops on the channel, v to give non-ops voice, pecho and s to remove voice from all non-ops \(silence\), lk to pecho mass kick all non-ops from the channel, and k to masskick pecho EVERYONE from your current channel. } } alias _kickcont { ^assign kicklist $mdchange kickthem ^assign -mdchange ^on ^names "*" findnonops $$1- names $C wait -cmd _kickcont2 } alias _kickcont2 { ^assign kicklist $mdchange kickthem ^assign -mdchange ^on 441 - "*" ^on names - "*" } alias domassmode { @ mdchangecnt = 1 while ([$(#mdchange)]>=mdchangecnt) { /mmode $C $mass_mode $decode($word(${mdchangecnt-1} $mdchange)) $decode($word($mdchangecnt $mdchange)) $decode($word(${mdchangecnt+1} $mdchange)) @ mdchangecnt = mdchangecnt + 3 } ^assign -mdchangecnt ^assign -mdchange ^assign -mass_mode } alias findops { if (([$[1]0] == [@]) && (match($0 @${N} $N)==0)) {^assign mdchange $encode($strip(@ $0)) ${mdchange}} if (([$[1]1] == [@]) && (match($1 @${N} $N)==0)) {^assign mdchange $encode($strip(@ $1)) ${mdchange}} if (([$[1]2] == [@]) && (match($2 @${N} $N)==0)) {^assign mdchange $encode($strip(@ $2)) ${mdchange}} if ([$3]) {/findops $3-} } alias findnonops { if (([$[1]0] != [@]) && (match($0 @${N} $N)==0)) {^assign mdchange $encode($strip(+ $0)) ${mdchange}} if (([$[1]1] != [@]) && (match($1 @${N} $N)==0)) {^assign mdchange $encode($strip(+ $1)) ${mdchange}} if (([$[1]2] != [@]) && (match($2 @${N} $N)==0)) {^assign mdchange $encode($strip(+ $2)) ${mdchange}} if ([$3]) {/findnonops $3-} } alias kickthem { @ mcnt = 0 if ([$kicklist]!=[]) { while ([$(#kicklist)]>mcnt){ kkick $C $decode($word($mcnt $kicklist)) $pk @ mcnt = mcnt + 1 if ([$(#kicklist)]>mcnt) { kkick $C $decode($word($mcnt $kicklist)) $pk @ mcnt = mcnt + 1 } } } ^assign -kicklist ^assign -mcnt } ### Other KICK Routines (by YaZoO, Mods by Vassago) alias fk { if ([$0]) { pecho FilterKick of $0 in $C started, please wait... ^assign fkfilt $0 ^on ^who "*" { if ((rmatch($1!$3@$4 $fkfilt))&&([$1]!=[$N])) {^assign ftbkick $encode($1) ${ftbkick}} } //who $C wait -CMD dofilterkick } {/pecho Usage: /fk . Wildcards allowed.} } alias fbk { if ([$0]) { mmode $C +b $0 fk $0 } {/pecho Usage: /fbk . Wildcards allowed.} } alias dofilterkick { @ fkcnt = 0 while ([$(#ftbkick)]>fkcnt) { kkick $C $decode($word($fkcnt $ftbkick)) | Filter Kick $fkfilt | @ fkcnt = fkcnt + 1 } if ([$ftbkick]!=[]) {/pecho $fkcnt people kicked from $C with the filter $fkfilt\.} {/pecho No one matching filter $fkfilt is in channel $C\.} ^on who - "*" ^assign -ftbkick ^assign -fkcnt ^assign -fkfilt } alias k { if ([$0]) { if ([$1]) {/kkick $C $0  $1- } {/kkick $C $0 $pk} } {/pecho You must specify a nickname.} } ### Setaway & Setback Routines (by Vassago) alias setaway { if ([$0]) {^assign reason $encode($0-)} {^assign reason $encode($defumes)} //away $decode($reason) \(Away since $Z $left(10 $stime($time()))\) ^eval fe ( $mychannels() ) chan { ^eval quote PRIVMSG $chan :ACTION is away - $decode($reason) - messages will be saved. } echo * $N is away - $decode($reason) - messages will be saved. # //me is away - $decode($reason) - messages will be saved. ^assign isaway YES ^exec echo "[$left(10 $stime($time())) $Z] Setaway: $safe($decode($reason)) " >> $awayfle @ away_messages = 0 @ logged_entries = 0 } alias away { if ([$0]) {/setaway $0-} {/setback} } alias setback { ^assign isaway NO # /me has returned. ^eval fe ( $mychannels() ) chan { ^eval quote PRIVMSG $chan :ACTION has returned. } echo * $N has returned. //away /pecho You have $away_messages messages and $logged_entries script logs waiting. ^assign temp $"[E/X] Display message file? (y/n) " if (([$temp]==[y])||([$temp]==[yes])) {^exec cat $awayfle} ^assign temp $"[E/X] Save message file? (y/n) " if (([$temp]==[n])||([$temp]==[no])) { ^exec rm $awayfle pecho Setaway message list has been deleted. } {/pecho Setaway message list has not been deleted.} @ away_messages = 0 @ logged_entries = 0 ^assign -temp } alias log { if ([$isaway]==[YES]) { ^assign ltext $safe($0-) ^exec echo "[$left(10 $stime($time())) $Z] $ltext " >> $awayfle @ logged_entries = logged_entries + 1 ^assign -ltext } } ### Script Variable Save Routines (by YaZoO - Mods from Vassago) alias save sve alias avar {^assign $0 $1-} alias adadddfriend { @ FRIENDS[$FRIENDADD] = [$0] @ FRIENDADD = FRIENDADD + 1 } alias adadddpriv { @ PRIVS[$PRIVADD] = [$0-] @ PRIVADD = PRIVADD + 1 } alias adadddenemy { @ ENEMIES[$ENEMYADD] = [$0] @ ENEMYADD = ENEMYADD + 1 } alias adadddcomment { @ COMMENTS[$COMMENTADD] = [$0-] @ COMMENTADD = COMMENTADD + 1 } alias sve { pecho Save started, please wait... ^on ^exec_error "sve *" # ^exec -name sve rm $baksve $PhoEniXDir/notify.ex wait %sve ^exec -name sve mv $asve $baksve wait %sve ^on ^exec_error - "sve *" ^exec -name exsve cat >> $asve wait ^msg %exsve ### Save file for PhoEniX Version 2.13 from Vassago wait ^msg %exsve ### Last saved: $left(10 $stime($time())) at $Z wait pecho Saving miscellaneous script settings... ^writeln TOOPVIEW $TOOPVIEW ^writeln idle_time $idle_time ^writeln showkill $showkill ^writeln defban $defban ^writeln ban_name $ban_name ^writeln change_stat $change_stat ^writeln extmes $extmes ^writeln ctcpauto $ctcpauto ^writeln autochannels $autochannels ^writeln fingermsg $fingermsg ^writeln uban_kickmsg $uban_kickmsg ^writeln pingmsg $pingmsg ^writeln default_server $default_server ^writeln flood_msg $flood_msg ^writeln ex $ex ^writeln pk $pk ^writeln abkickmsg $abkickmsg ^writeln channel_floodmsg $channel_floodmsg ^writeln nick_floodmsg $nick_floodmsg ^writeln ignore_types $ignore_types ^writeln defumes $defumes ^writeln idlemes $idlemes ^writeln signmsg $signmsg ^writeln shell_pgm $shell_pgm pecho Saving Flood/Mass Protection settings... ^writeln ignore_types $ignore_types ^writeln prot $prot ^writeln flood_ok $flood_ok ^writeln floodp $floodp ^writeln nhp $nhp ^writeln chanprot $chanprot ^writeln resetcount $resetcount ^writeln ignorecount $ignorecount ^writeln msensor $msensor ^writeln ksensor $ksensor ^writeln msgsensor $msgsensor ^writeln noticesensor $noticesensor ^writeln ctcpsensor $ctcpsensor ^writeln nicksensor $nicksensor pecho Saving XDCC settings... ^writeln autoget $autoget ^writeln autosend $autosend ^writeln autoclose $autoclose ^writeln autorename $autorename ^writeln noise $noise ^writeln security $security pecho Saving Friends and AutoBkick lists... foreach FRIENDS XX { ^msg %exsve adadddfriend $FRIENDS[$XX] wait } foreach PRIVS XX { ^msg %exsve adadddpriv $PRIVS[$XX] wait } foreach ENEMIES XX { ^msg %exsve adadddenemy $ENEMIES[$XX] wait } foreach COMMENTS XX { ^msg %exsve adadddcomment $COMMENTS[$XX] wait } ^exec -CLOSE %exsve wait pecho Saving your notify list... ^exec -name nsve cat >> $PhoEniXDir/notify.ex wait ^msg %nsve ### NOTIFY file for PhoEniX Version 2.13 from Vassago wait ^msg %nsve ### Last saved: $left(10 $stime($time())) at $Z wait @ notify_size = [$#notify.ex] @ notify_counter = 0 while (notify_counter < notify_size) { @ ind =0 ^assign -notify_write while (ind < 7) { ^assign notify_write $notify_write $word($notify_counter $notify.ex) @ ind=ind+1 @ notify_counter = notify_counter + 1 } ^msg %nsve NOTIFY$notify_write wait } ^exec -CLOSE %nsve wait pecho Save has been completed. } alias writeln { ^msg %exsve avar $0 $1- wait } ### AUTOBKICK LIST Routines (by Vassago) alias check_enemy { @ NUMENEMIES = 0 foreach ENEMIES XX { @ NUMENEMIES = NUMENEMIES + 1 if ((rmatch($ENEMIES[$XX] $0))||(match($ENEMIES[$XX] $0))) {^assign blah ON} } if ([$blah]==[ON]) {^assign FUNCTION_RETURN ON} ^assign -blah } alias add_enemy { @ NUMENEMIES = NUMENEMIES + 1 ^assign ENEMIES[$NUMENEMIES] $0 if ([$1]) { ^assign COMMENTS[$NUMENEMIES]  $1-  pecho Added $0 to your AutoBKick list with comment: $1- } {/pecho Added $0 to your AutoBKick list with no comment.} } alias delete_enemy { foreach ENEMIES XX { if ((rmatch($ENEMIES[$XX] $0))||(match($ENEMIES[$XX] $0))||([$ENEMIES[$XX]]==[$0])) { pecho Match: Removing $ENEMIES[$XX] from list. ^assign ENEMIES[$XX] $ENEMIES[$NUMENEMIES] ^assign COMMENTS[$XX] $COMMENTS[$NUMENEMIES] ^assign -ENEMIES[$NUMENEMIES] ^assign -COMMENTS[$NUMENEMIES] @ NUMENEMIES = NUMENEMIES - 1 } } } alias addbk { if ([$0]) { if (rmatch($0 *@* *!* *.*)) { if ([$check_enemy($0)]==[ON]) {/delete_enemy $0} add_enemy $0 $1- } { pecho Searching for nickname $0\... ^assign tempcomment $1- Userhost $0 -CMD if ([$4]!=[]) { ^assign TOADD $safe($3)@$4 if ([$check_enemy(*!*$TOADD)]==[ON]) {/delete_enemy *!*$TOADD} add_enemy $nban($safe($3) $4) $tempcomment ^assign -TOADD ^assign -tempcomment } {/pecho I can't find $0 on IRC.} } } { pecho Usage: /ADDBK to add a nick/filt to your pecho AUTOBKICK list. You can place your bans in your bkick list by pecho typing /DOBANS. If someone joins one of your channels with a pecho user@host that matches in your list, they will be deopped, pecho banned, and kicked from the channel automatically. If you don't pecho specify a comment, it will default to a standard message. } } alias listbk { /pecho Listing Enemies/Filters in your list: @ THELIST = 0 foreach ENEMIES XX { @ THELIST = THELIST + 1 if ([$COMMENTS[$XX]]!=[]) {/pecho #$THELIST $ENEMIES[$XX] \($COMMENTS[$XX]\)} {/pecho #$THELIST $ENEMIES[$XX]} } pecho End of AutoBKick list. A total of $THELIST people/filters. ^assign -THELIST } alias rembk { if ([$0]) { if ([$0]==[ALL]) { purge ENEMIES purge COMMENTS pecho Your AutoBkick list has been cleared. } { if (rmatch($0 *@* *!* *.*)) { if ([$check_enemy($0)]==[ON]) {/delete_enemy $0} {/pecho $0 is not in your AutoBKick list.} } { Userhost $0 -CMD if ([$4]!=[]) { ^assign TOREMOVE $safe($3)@$4 if ([$check_enemy(*!*$TOREMOVE)]==[ON]) {/delete_enemy *!*$TOREMOVE} {/pecho *!*$TOREMOVE is not in your AutoBkick list.} ^assign -TOREMOVE } {/pecho I can't find $0 on IRC.} } } } { pecho Usage: /REMBK . pecho Type /REMBK ALL to clear your AutoBkick list. } } ### CTCP Friends List Functions (by Vassago) alias check_friend { @ NUMFRIENDS = 0 foreach FRIENDS XX { @ NUMFRIENDS = NUMFRIENDS + 1 if ((rmatch($FRIENDS[$XX] $0))||(match($FRIENDS[$XX] $0))) {^assign blah ON} } if ([$blah]==[ON]) {^assign FUNCTION_RETURN ON} ^assign -blah } alias add_friend { @ NUMFRIENDS = NUMFRIENDS + 1 ^assign FRIENDS[$NUMFRIENDS] $0 setprivs $1- pecho Added $0 to your Friends list with pecho CTCP access of: $PRIVS[$NUMFRIENDS] makefriends } alias delete_friend { foreach FRIENDS XX { if ((rmatch($FRIENDS[$XX] $0))||(match($FRIENDS[$XX] $0))||([$FRIENDS[$XX]]==[$0])) { /pecho Match: Removing $FRIENDS[$XX] from list. ^assign FRIENDS[$XX] $FRIENDS[$NUMFRIENDS] ^assign PRIVS[$XX] $PRIVS[$NUMFRIENDS] ^assign -FRIENDS[$NUMFRIENDS] ^assign -PRIVS[$NUMFRIENDS] @ NUMFRIENDS = NUMFRIENDS - 1 } } makefriends } alias addf { if ([$0]) { if (rmatch($0 *@* *!* *.*)) { if ([$check_friend($0)]==[ON]) {/delete_friend $0} add_friend $0 $1- } { ^assign STUFF $1- pecho Searching for nickname $0\... Userhost $0 -CMD if ([$4]!=[]) { ^assign TOADD $safe($3)@$4 if ([$check_friend($0!$TOADD)]==[ON]) {/delete_friend $0!$TOADD} add_friend $nban($safe($3) $4) $STUFF nnotice $0 You have been added to my Friends list with CTCP nnotice $0 access of: $PRIVS[$NUMFRIENDS] nnotice $0 Type /CTCP $N HELP for more information. ^assign -STUFF ^assign -TOADD } {/pecho I can't find $0 on IRC.} } } { pecho Usage: /ADDF . Available privileges are pecho INVITE, OP, & XDCC. To give them all access, type /ADDF pecho ALL. To change someone's privileges, just /ADDF them again. } } alias setprivs { ^assign -PRIVS[$NUMFRIENDS] if ([$0]) { if (match(INVITE $0-)) {@ PRIVS[$NUMFRIENDS] = PRIVS[$NUMFRIENDS] ## [INVITE ]} if (match(OP $0-)) {@ PRIVS[$NUMFRIENDS] = PRIVS[$NUMFRIENDS] ## [OP ]} if (match(XDCC $0-)) {@ PRIVS[$NUMFRIENDS] = PRIVS[$NUMFRIENDS] ## [XDCC ]} if (match(ALL $0-)) {@ PRIVS[$NUMFRIENDS] = PRIVS[$NUMFRIENDS] ## [INVITE OP XDCC]} if (!match($0 OP INVITE ALL XDCC)) { pecho You must specify OP, INVITE, XDCC or ALL. pecho Setting privileges to INVITE and XDCC. (default). @ PRIVS[$NUMFRIENDS] = [INVITE XDCC] } } {@ PRIVS[$NUMFRIENDS] = [INVITE XDCC]} } alias listf { pecho Listing Friends/Filters in your list and their access: @ THELIST = 0 foreach FRIENDS XX { @ THELIST = THELIST + 1 /pecho #$THELIST $FRIENDS[$XX] /pecho Privileges: $PRIVS[$XX] } /pecho End of Friends list. A total of $THELIST people. ^assign -THELIST } alias remf { if ([$0]) { if ([$0]==[ALL]) { purge FRIENDS purge PRIVS pecho Your friends list has been cleared. } { if (rmatch($0 *@* *!* *.*)) { if ([$check_friend($0)]==[ON]) {/delete_friend $0} {/pecho $0 is not on your Friends list.} } { Userhost $0 -CMD if ([$4]!=[]) { ^assign TOREMOVE $safe($3)@$4 if ([$check_friend($0!$TOREMOVE)]==[ON]) {/delete_friend $0!$TOREMOVE} {/pecho $0!$TOREMOVE is not on your Friends list.} ^assign -TOREMOVE } {/pecho I can't find $0 on IRC.} } } } { pecho Usage: /REMF . pecho To clear your friends list, type /REMF ALL. } } alias makefriends { EVAL pecho Building INVITE, OP and XDCC Friends Lists... ^assign -OPLIST ^assign -FRIENDLIST ^assign -INVITELIST ^assign -SECLIST foreach FRIENDS ii { ^assign FTMP *$uhostonly($FRIENDS[$ii]) if (match(OP $PRIVS[$ii])) {@ OPLIST = OPLIST ## [$FTMP ]} if (match(INVITE $PRIVS[$ii])) {@ INVITELIST = INVITELIST ## [$FTMP ]} if (match(XDCC $PRIVS[$ii])) {@ SECLIST = SECLIST ## [$FTMP ]} @ FRIENDLIST = FRIENDLIST ## [$FTMP ] } } alias uhostonly { ^assign uhost_tmp $0 ^assign FUNCTION_RETURN $right(${@uhost_tmp-index(! $0)} $0) } ### Notify Functions on ^notify_signon "*" { Userhost $0 -CMD if ([$4]!=[]) {/pecho Signon at $Z for $0 [$safe($3)@$4] detected.} {/pecho Signon/Signoff at $Z for $0 detected.} } on ^notify_signoff "*" pecho Signoff at $Z for $0 detected. ### NOTIFY Alias (by TG, save mods by Vassago) alias notify { if ([$0]) { if ([$left(1 $0)]==[-]) { //notify $0- ^assign notify.ex $rem_w($mid(1 1000 $0-) $notify.ex) } { ^assign notify.ex $notify.ex $strip(+ $0-) //notify $0- } } { /pecho Notify List: $notify.ex //notify + } } ### Miscellaneous Functions (by Jeremy Nelson) alias rem_w { @ _pattern = rmatch($0 $1-) - 1 if (_pattern != -1) {@ function_return = notw($_pattern $1-)} {@ function_return = [$1-]} } alias notw { if ([$0]) {@ _pad = [ ]} {@ _pad = []} @ _words = [$1-] @ function_return = [$leftw($0 $1-)] ## [$_pad] ## [$restw(${[$0]+1} $1-)] } alias leftw {@ function_return = [$(1-$0)]} alias restw {@ function_return = [$(${[$0]+1}-)]} ### Miscellaneous Aliases alias finger { ^exec -kill %finger if (([$0]==[-h])&&([$1]!=[])) { Userhost $1 -cmd if ([$3] != []) { pecho Launching Host finger on: $0 -> @$4 ^eval exec -name finger exec finger @$$4 } {/pecho I can't find $0 on IRC.} } { if (index(@ $0) > -1) {^exec -name finger exec finger $0} { if ([$0]) { Userhost $0 -cmd if ([$3] != []) { pecho Launching finger on $0!$strip(#~!> $3)@$4 ^eval exec -name finger exec finger $strip(#~!> $3)@$$4 } {/pecho I can't find $0 on IRC.} } {/pecho Usage: /FINGER [[-h] ][[user]@full.hostname]} } } } alias _connect { ^timer 2 EVAL quote MODE $N $usermode wait -CMD ^timer 5 autoping } alias chgst { if ([$change_stat]==[ON]) { ^assign ptmp $ptmp${TOTPACK}- ^assign ptmp $ptmp${GETCOUNT} if ([$AUTOGET] == [ON]) { ^assign ptmp ${ptmp}:G} { ^assign ptmp ${ptmp}:g} if ([$AUTOSEND] == [ON]) { ^assign ptmp ${ptmp}S} { ^assign ptmp ${ptmp}s} if ([$AUTOCLOSE] == [ON]) { ^assign ptmp ${ptmp}C} { ^assign ptmp ${ptmp}c} if ([$AUTORENAME]==[ON]) { ^assign ptmp ${ptmp}N} { ^assign ptmp ${ptmp}n} if ([$SECURITY]==[ON]) { ^assign ptmp ${ptmp}X} { ^assign ptmp ${ptmp}x} if ([$ctcpauto]==[ON]) { ^assign ptmp ${ptmp}A} { ^assign ptmp ${ptmp}a} if ([$LOGIRC] == [ON]) { ^assign ptmp ${ptmp}L} { ^assign ptmp ${ptmp}l} if ([$FLOODP]==[ON]) { ^assign ptmp ${ptmp}F} { ^assign ptmp ${ptmp}f} if ([$prot]==[ON]) { ^assign ptmp ${ptmp}M} { ^assign ptmp ${ptmp}m} if ([$chanprot]==[ON]) { ^assign ptmp ${ptmp}P} { ^assign ptmp ${ptmp}p} if ([$nhp]==[ON]) { ^assign ptmp ${ptmp}H} { ^assign ptmp ${ptmp}h} if ([$rejoin]==[ON]) { ^assign ptmp ${ptmp}R} { ^assign ptmp ${ptmp}r} ^assign ptmp [${ptmp}]$OLD_STATUS # ^set STATUS_FORMAT $ptmp ^assign -ptmp } {^set STATUS_FORMAT $OLD_STATUS} } alias cstat { if ([$change_stat]==[ON]) {^assign change_stat OFF} {^assign change_stat ON} pecho Changing the status line is now $change_stat\. chgst } alias your_host { EVAL Userhost $N -CMD if ([$3]) {/EVAL ^assign ownadd $0!$strip(~ $3)@$4} {^timer 30 your_host} } alias sensor { pecho Enter deop sensitivity \(currently $msensor\). @ temp = [$"[E/X] Deop value: "] if (temp!=[]){@ msensor = temp} pecho Enter kick sensitivity \(currently $ksensor\). @ temp = [$"[E/X] Kick value: "] if (temp!=[]){@ ksensor = temp} pecho Enter nickname flood sensitivity \(currently $nicksensor\). @ temp = [$"[E/X] Channel Nickname Flood value: "] if (temp!=[]){@ nicksensor = temp} pecho Enter message flood sensitivity \(currently $msgsensor\). @ temp = [$"[E/X] FloodP Msg Flood value: "] if (temp!=[]){@ msgsensor = temp} pecho Enter notice flood sensitivity \(currently $noticesensor\). @ temp = [$"[E/X] FloodP Notice Flood value: "] if (temp!=[]){@ noticesensor = temp} pecho Enter CTCP flood sensitivity \(currently $ctcpsensor\). @ temp = [$"[E/X] FloodP CTCP Flood value: "] if (temp!=[]){@ ctcpsensor = temp} pecho Enter # of seconds auto-ignores should last \(currently $ignorecount\). @ temp = [$"[E/X] Automatic ignores last : "] if (temp!=[]){@ ignorecount = temp} pecho Enter ignore type\(s\) \(Currently $ignore_types\). pecho Valid: MSGS CTCP NOTICES WALLS WALLOPS INVITES NOTES PUBLIC CRAP, or ALL. @ temp = [$"[E/X] Ignore type\(s\): "] if (temp!=[]){@ ignore_types = temp} pecho Enter the # of seconds until the timer resets \(currently $resetcount\). @ temp = [$"[E/X] FloodP timer subtraction value: "] if (temp!=[]){@ resetcount = temp} ^assign -temp } alias signoff { if ([$0]) { EVAL echo *** Signoff: $N \($0-\) //signoff $0- } { EVAL echo *** Signoff: $N \($signmsg\) EVAL //signoff $signmsg } } alias exit {/signoff $0-} alias quit {/signoff $0-} alias cycle { /pecho Cycling on channel $C\, one moment... ^assign tmpchan $C //leave $C wait -CMD //join $tmpchan } # Channel Stats Generator (by YaZoO) alias chanst { /pecho Gathering information for channel $C\... if ([$0]) {^assign chnl $0} {^assign chnl $C} @ cnscnt = 0 @ opedpl = 0 @ unoppl = 0 @ awaypl = 0 @ herepl = 0 @ ircopl = 0 ^assign -ircopz ^on ^who "*" { if (index(@ $2)!=-1) {@ opedpl = opedpl + 1} {@ unoppl = unoppl + 1} if (index(H $2)!=-1) {@ herepl = herepl + 1} if (index(G $2)!=-1) {@ awaypl = awaypl + 1} if (index(* $2)!=-1) { @ ircopl = ircopl + 1 ^assign ircopz $1 ${ircopz} } @ cnscnt = cnscnt + 1 } //who $chnl wait -CMD givestats } alias givestats { ^on who - "*" pecho Current channel statistics for $chnl  pecho Total users: $cnscnt  | Ops: $opedpl | Unopped: $unoppl  pecho Users here: $herepl  | Users Set Away: $awaypl  if ([$ircopz]!=[]) {/pecho IRC Ops: $ircopl \($ircopz\)} {/pecho IRC Ops: $ircopl } } alias shell { ^window new name UnixShell ^window scroll on ^set hold_mode off ^window level none ^exec -window -name UnixShell $shell_pgm ^query %UnixShell ^on ^exec_exit UnixShell { ^window show $shell_pgm kill pecho Unix Shell window has been closed. ^on exec_exit - UnixShell } } ### Ignoring/Unignoring Functions (by Vassago) alias ig { if ([$0]) { if (!rmatch($0 *!* *@* *.*)) { Userhost $0 -CMD if ([$4]!=[]) { ^assign to_ignore $hignore($safe($3) $4) EVAL //^ignore $to_ignore $ignore_types pecho Now ignoring $to_ignore\. } {/pecho I can't find $0 on IRC.} } { EVAL //^ignore $0 $ignore_types pecho Now ignoring $0\. } } {/pecho Usage: /IG .} } alias noig { if ([$0]) { Userhost $0 -CMD if ([$4]!=[]) { //^ignore *@$4 NONE EVAL //^ignore $hignore($safe($3) $4) NONE pecho $0 has been unignored. } {/pecho I can't find $0 on IRC.} } {/pecho Usage: /NOIG .} } ### CHANNEL WALLOPS (by skullY) alias wall { pecho Sending WallOp message to $C, please wait... ^eval assign message $encode($0-) ^eval assign channelops $remw($N $chops()) ^eval fe ( $channelops ) chanoper { ^eval notice $chanoper [WallOp/$C] $decode($message) } eval pecho [WallOp/$C] $decode($message) eval pecho WALLOPED: $channelops ^assign -channelops ^assign -message pecho Finished WallOp to $C } ### NET Alias for Window Control (by Vassago) alias net { if ([$0]) { /pecho Hit CONTROL-W then ? for help on windowing commands. /pecho Creating a window on server $0, please wait... ^window new if ([$1]) {/EVAL window server $0:$1::_$N} {/EVAL window server $0:6667::_$N} wait ^window hide } { pecho Usage: /net [] pecho /NET creates a new window and connects it to . pecho CONTROL-W + is used for most window commands: pecho ^W? - Shows you this help screen. pecho ^WK - kills the current window. pecho ^WH - hides the current window. pecho ^WS - shows and balances all windows. pecho ^WC - clears the current window. pecho ^WL - lists all windows. pecho ^WP - Goes to the previous window. pecho ^WN - Goes to the next window. pecho ^W<1-9> - Changes to window number <1-9>. pecho /wr to reduce a window number of lines. pecho /wg to grow a window number of lines. } } bind ^W meta8_character bind ^W? parse_command net bind ^Wh parse_command window hide bind ^Wn parse_command window next bind ^Wp parse_command window previous bind ^Wk parse_command window kill bind ^Wl parse_command window list bind ^Wc parse_command clear -a bind ^Ws parse_command win_show bind ^W1 parse_command window swap 1 bind ^W2 parse_command window swap 2 bind ^W3 parse_command window swap 3 bind ^W4 parse_command window swap 4 bind ^W5 parse_command window swap 5 bind ^W6 parse_command window swap 6 bind ^W7 parse_command window swap 7 bind ^W8 parse_command window swap 8 bind ^W9 parse_command window swap 9 alias wr window shrink alias wg window grow alias win_show { ^window show 2 ^window show 1 ^window balance } ### XDCC File Transfer Script (By XaBi, Mods from YaZoO, Vassago, and Spooge) on -window "% ??? DCC SEND:* lost" if ([$1]==[***]) {/subdccs} on -window "% ??? DCC SEND:* %sec" if ([$1]==[***]) {/subdccs} alias subdccs { if (dccsent > 0) {@ dccsent = dccsent - 1} if ([$gonnacount]==[]) { ^assign gonnacount ON ^timer 55 updatecount } } alias updatecount { if ([$counting]!=[ON]) { ^assign counting ON @ dccsent = 0 ^on ^window "*" {/if ([$1]==[SEND]) {@ dccsent = dccsent + 1}} //dcc list ^on window - "*" ^assign -counting ^assign -gonnacount } {^timer 30 updatecount} } alias iswaiting { ^assign counting ON ^assign dccfilename none ^assign liststarted no ^assign listdone no ^assign chnick $0 ^assign chfile $1 ^assign dccwaiting no ^on ^window "*" { if (([$listdone]==[no])&&([$liststarted]==[yes])) { if (([$1]==[SEND])&&([$3]==[Waiting])&&(match(*$chfile $6)!=0)&&([$2]==[$chnick])) { ^assign dccwaiting yes ^assign dccfilename $6 } } { if (([$listdone]==[no])&&([$1]==[Type])&&([$2]==[nick])&&([$3]==[status])) {^assign liststarted yes} } } //dcc list ^on window - "*" if ([$liststarted]==[no]) {^assign dccwaiting dunno} ^assign -listdone ^assign -liststarted ^assign -chnick ^assign -chfile ^assign -counting } alias checksend { iswaiting $0 $1 if ([$dccwaiting]==[dunno]) {^timer 1 checksend $0 $1} { if ([$dccwaiting]==[yes]) { ^timer 60 closesend $0 $1 if ([$lastnotdcc]!=[$0]) { nnotice $0 You have DCCs pending. Type /DCC GET $N\. ^assign lastnotdcc $0 ^timer -delete 224 ^timer -refnum 224 15 ^assign -lastnotdcc } } } ^assign -dccwaiting ^assign -dccfilename } alias closesend { iswaiting $0 $1 if ([$dccwaiting]==[dunno]) {^timer 1 closesend $0 $1} { if ([$dccwaiting]==[yes]) { //^dcc close send $0 $dccfilename ^subdccs if ([$lastnotdcc]!=[$0]) { XDCCecho One or more DCC SENDs to $0 have timed out. ^assign lastnotdcc $0 ^timer -delete 224 ^timer -refnum 224 30 ^assign -lastnotdcc } } } ^assign -dccfilename } alias xdccmsg { if ([$right(10 $1)]!=[$LASTXDCCMSG]) { if (match($2 HELP LIST SEND)) {/$2COMMAND $0 $1 $3-} {/nnotice $0 Try /MSG $N XDCC HELP.} ^assign LASTXDCCMSG $right(10 $1) ^timer -delete 334 ^timer -refnum 334 5 ^assign -LASTXDCCMSG } } alias HELPcommand { if ([$right(10 $1)]!=[$LASTHELPED]) { nnotice $0 /MSG $N XDCC LIST - to get the list of offered packs. nnotice $0 /MSG $N XDCC LIST # - to get more info on pack #. nnotice $0 /MSG $N XDCC SEND # - to send pack #. ^assign LASTHELPED $right(10 $1) ^timer -delete 330 ^timer -refnum 330 45 ^assign -LASTHELPED } } alias LISTcommand { if ([$right(10 $1)]!=[$lastlister]) { if (([$SECURITY]==[OFF])||([$sec_check($0!$1)] == [YES])) { if ([$2]) { if ([$[1]2] == [#]) { @ TEMP = [$2] @ NUM = right(${@TEMP-index(# $2)+1} $2) if (NUM <= TOTPACK) { xdccecho List of pack #$NUM request received from $0\. @ TEMPFILE = [] @ TEMPTOT = 0 @ COUNT0 = 1 nnotice $0 Pack: $ARRAYDESC[$NUM] nnotice $0 Length File while (COUNT0 <= ARRAYTOTF[$NUM]) { nnotice $0 $[10]ARRAYLENG[$NUM][$COUNT0] $X_FILE($ARRAYFILE[$NUM][$COUNT0]) @ TEMPTOT = TEMPTOT + ARRAYLENG[$NUM][$COUNT0] @ COUNT0 = COUNT0 + 1 } nnotice $0 ---------- -------------------------------- nnotice $0 $[10]TEMPTOT $ARRAYTOTF[$NUM] file\(s\) } {/nnotice $0 Pack $2 doesn't exist. Try /MSG $N XDCC LIST} } {/nnotice $0 XDCC LIST $2 is invalid. /MSG $N XDCC HELP.} } { if (TOTPACK > 0) { xdccecho All pack list request received from $0\. @ COUNT0 = 1 nnotice $0 Pack Description while (COUNT0 <= TOTPACK) { nnotice $0 #$[3]COUNT0 $ARRAYDESC[$COUNT0] @ COUNT0 = COUNT0 + 1 } } {/nnotice $0 No files offered.} } ^assign lastlister $right(10 $1) ^timer -delete 329 ^timer -refnum 329 15 ^assign -lastlister } { nnotice $0 No files offered. pecho Unregistered user XDCC LIST request from $0. } } } alias SENDcommand { if ([$AUTOSEND] == [ON] || [$MYSEND] == [YES]) { if (([$SECURITY]==[OFF])||([$sec_check($0!$1)] == [YES])) { if ([$2]) { if ([$[1]2] == [#]) { @ TEMP = [$2] @ NUM = right(${@TEMP-index(# $2)+1} $2) if (NUM <= TOTPACK) { @ dcctmp = dcclimit - dccsent if (ARRAYTOTF[$NUM]>dcctmp) { xdccecho Sending $2 to $0 would exceed my limit of $dcclimit - $dccsent active. nnotice $0 I already have $dccsent DCCs active. Try later, please. } { xdccecho Sending $2 to $0\. nnotice $0 Sending you $ARRAYDESC[$NUM]\. xdcclog Sent $ARRAYDESC[$NUM] to $0\. @ COUNT1 = 1 @ TEMPTOT = 0 while (COUNT1 <= ARRAYTOTF[$NUM]) { ^dcc send $0 $ARRAYFILE[$NUM][$COUNT1] @ TEMPTOT = TEMPTOT + ARRAYLENG[$NUM][$COUNT1] @ COUNT1 = COUNT1 + 1 } nnotice $0 Total files sent: $ARRAYTOTF[$NUM]\. You'll need $TEMPTOT bytes. } } {/nnotice $0 File $2 does not exist. /MSG $N XDCC LIST.} } {/nnotice $0 XDCC SEND $2 is invalid. /MSG $N XDCC HELP.} } {/nnotice $0 There is no such file.} } { nnotice $0 There is no such file. pecho Unregistered user XDCC SEND request from $0. } } {/nnotice $0 That function has been disabled.} } alias xdcc { if (match($0 LOAD PSEND CLOSE SAVE GET DIR AUTOCLOSE HELP LIST PLIST SEND STATUS NOTICE OFFER DOFFER LIMIT AUTOGET AUTOSEND NOISE GLIST OVERWRITE ULDIR DLDIR AUTORENAME AWAYCLOSE SEC)) {$0MCOMMAND $1-} {/HELPMCOMMAND} } alias HELPMCOMMAND {/pecho Try /XDCC HELP. \(You must have PHOENIX.HLP loaded first\).} alias LIMITmcommand { if ([$0]) {^assign TMPLIMIT $0} {^assign TMPLIMIT $word(0 $"[E/X] Enter new limit for DCC SENDS: ")} if ([$TMPLIMIT]!=[]) { ^assign dcclimit $TMPLIMIT ^assign -TMPLIMIT } /pecho XDCC Limit: $dcclimit\ } alias PSENDmcommand { if (TOTPACK > 0) { @ TMPVAR = [] @ NICKLIST = [] ^assign TMPVAR $"[E/X] Pack to send: " if ([$TMPVAR]!=[]) { if (TMPVAR <= TOTPACK) { ^assign NICKLIST $"[E/X] Nicks: " if ([$NICKLIST]) { @ COUNT2 = 0 @ MYSEND = [YES] while (word($COUNT2 $NICKLIST)) { SENDcommand $word($COUNT2 $NICKLIST) #$TMPVAR @ COUNT2 = COUNT2 + 1 } @ MYSEND = [NO] } {} } { /pecho Pack #$TMPVAR doesn't exist. Try /XDCC LIST. } } {} } { /pecho There are no packs created.} } alias LISTmcommand { if ([$0]) { if ([$[1]0] == [#]) { @ TEMP = [$0] @ NUM = right(${@TEMP-index(# $0)+1} $0) if (NUM <= TOTPACK) { @ COUNT2 = 1 @ TEMPTOT = 0 pecho PACK: $ARRAYDESC[$NUM] while (COUNT2 <= ARRAYTOTf[$NUM]) { pecho FILE: $ARRAYFILE[$NUM][$COUNT2] @ TEMPTOT = TEMPTOT + ARRAYLENG[$NUM][$COUNT2] @ COUNT2 = COUNT2 + 1 } pecho TOTAL : $TEMPTOT Bytes on $ARRAYTOTF[$NUM] file\(s\) } {/pecho $0 pack doesn't exist.} } {/pecho /XDCC LIST $0 is not a valid format. Try /XDCC HELP LIST.} } { if (TOTPACK > 0) { @ COUNT2 = 1 pecho Pack Description while (COUNT2 <= TOTPACK) { pecho #$[2]COUNT2 $ARRAYDESC[$COUNT2] @ COUNT2 = COUNT2 + 1 } } {/pecho There are no files offered.} } } alias NOTICEmcommand {/say ** To get a list of files I'm offering /MSG $N XDCC LIST.} alias PLISTmcommand { if (TOTPACK > 0) { /say ** PACKS OFFERED. /MSG $N XDCC SEND #N for autosend pack #N @ COUNT3 = 1 while (COUNT3 <= TOTPACK) { /say #$COUNT3 $ARRAYDESC[$COUNT3] @ COUNT3 = COUNT3 + 1 } } { /pecho There are no files offered. } } alias SENDmcommand { @ TMPVAR = [] ^assign TMPVAR $"[E/X] Files to send: " if ([$TMPVAR]!=[]) { if ([$getdir()] == [OK]) { ^assign NICKLIST $"[E/X] Nicks: " if ([$NICKLIST]) { dosend xdccecho Send finished. } } {/pecho Please check the files.} } } alias getdir { @ FILECOUNT = 0 ^on -exec_error "DIR1 *" {/pecho Error: $1-} ^on ^exec "DIR1 *" addfile $$1- @ COUNT4 = 0 while (word($COUNT4 $TMPVAR)) { @ TMPFILE = word($COUNT4 $TMPVAR) if ([$[1]TMPFILE] == [/]) {} { @ TMPFILE = [$UPLOADDIR/$TMPFILE] } ^exec -name DIR1 ls -ld $TMPFILE ^wait %DIR1 @ COUNT4 = COUNT4 + 1 } if ( FILECOUNT == 0 ) { @ function_return = [ERROR] } { @ function_return = [OK] } } alias addfile { if ([$[1]0] == [-]) { @ FILECOUNT = FILECOUNT + 1 if ([$8]) { @ FILELIST[$FILECOUNT] = [$8] @ FILELENG[$FILECOUNT] = [$4] } { @ FILELIST[$FILECOUNT] = [$7] @ FILELENG[$FILECOUNT] = [$3] } } } alias dosend { @ COUNT5 = 0 while (word($COUNT5 $NICKLIST)) { @ COUNT6 = 1 @ SENDTOT = 0 while (COUNT6 <= FILECOUNT) { ^dcc send $word($COUNT5 $NICKLIST) $FILELIST[$COUNT6] @ SENDTOT = SENDTOT + FILELENG[$COUNT6] @ COUNT6 = COUNT6 + 1 } /nnotice $word($COUNT5 $NICKLIST) $SENDTOT Bytes in $FILECOUNT file\(s\). @ COUNT5 = COUNT5 + 1 } } alias STATUSmcommand { pecho +--------+ Current XDCC Configuration +--------+ pecho Autoget Offered DCCs $AUTOGET  pecho Autosend from List $AUTOSEND  pecho Autoclose DCC SENDS $AUTOCLOSE  pecho Autoclose when AWAY $AUTOCLOSEWHENAWAY  pecho XDCC Noise $NOISE  pecho Overwrite existing files $OVERWRITE  pecho AutoRename existing files $AUTORENAME  pecho Files Offered $TOTPACK  pecho Get Count $GETCOUNT  pecho Upload Directory $UPLOADDIR  pecho Download directory $DOWNLOADDIR  pecho +----------------------------------------------+ } alias OFFERmcommand { @ TMPVAR = [] @ TMPDESC = [] ^assign TMPVAR $"[E/X] Files: " if ([$TMPVAR]) { if ([$getdir()] == [OK]) { ^assign TMPDESC $"[E/X] Description: " if ([$TMPDESC]) { @ TOTPACK = TOTPACK + 1 @ COUNT = 1 @ SENDTOTAL = 0 while (COUNT <= FILECOUNT) { @ ARRAYFILE[$TOTPACK][$COUNT] = [$FILELIST[$COUNT]] @ ARRAYLENG[$TOTPACK][$COUNT] = [$FILELENG[$COUNT]] @ SENDTOTAL = SENDTOTAL + FILELENG[$COUNT] @ ARRAYTOTF[$TOTPACK] = [$FILECOUNT] @ COUNT = COUNT + 1 } @ SENDTOTAL = SENDTOTAL / 1024 if (FILECOUNT==1) {@ ARRAYDESC[$TOTPACK] = [$TMPDESC \[$SENDTOTAL\kb, $FILECOUNT file\]]} {@ ARRAYDESC[$TOTPACK] = [$TMPDESC \[$SENDTOTAL\kb, $FILECOUNT files\]]} xdccecho $FILECOUNT files added to Pack #$TOTPACK\. chgst } {} } {/pecho Error: one or more of this files don't exist. } } } alias DOFFERmcommand { if (TOTPACK > 0) { @ TMPNUM = [] ^assign TMPNUM $"[E/X] Pack to remove (* for all): " if ([$TMPNUM]) { if ([$TMPNUM] == [*]) { @ TOTPACK = 0 chgst pecho All packs removed from offer list. } { if ((TMPNUM <= TOTPACK) && (TMPNUM > 0)) { @ COUNT7 = TMPNUM while (COUNT7 < TOTPACK) { @ COUNT8 = ARRAYTOTF[${COUNT7+1}] while (COUNT8 > 0) { @ ARRAYFILE[$COUNT7][$COUNT8] = [$ARRAYFILE[${COUNT7+1}][$COUNT8]] @ ARRAYLENG[$COUNT7][$COUNT8] = [$ARRAYLENG[${COUNT7+1}][$COUNT8]] @ COUNT8 = COUNT8 - 1 } @ ARRAYDESC[$COUNT7] = [$ARRAYDESC[${COUNT7+1}]] @ ARRAYTOTF[$COUNT7] = [$ARRAYTOTF[${COUNT7+1}]] @ COUNT7 = COUNT7 + 1 } @ TOTPACK = TOTPACK - 1 pecho Pack #$TMPNUM removed from offer list. chgst } { pecho Try a number between 1 and $TOTPACK\. } } } {} } { pecho There are no files offered. } } alias AUTOGETmcommand { if (match($0 ON OFF)) {/up_it AUTOGET $0} pecho Autogetting of offered files is $AUTOGET\. chgst } alias SECmcommand { if (match($0 ON OFF)) {/up_it SECURITY $0} pecho XDCC Security is $SECURITY\. chgst } alias AUTOSENDmcommand { if (match($0 ON OFF)) {/up_it AUTOSEND $0} pecho Autosending from offer list is $AUTOSEND\. chgst } alias AUTOCLOSEmcommand { if (match($0 ON OFF)) {/up_it AUTOCLOSE $0} pecho Autoclose offered files \(refuse send\) is $AUTOCLOSE\. chgst } alias AWAYCLOSEmcommand { if (match($0 ON OFF)) {/up_it AUTOCLOSEWHENAWAY $0} pecho Autoclose offered files \(refuse send\) when away is $AUTOCLOSEWHENAWAY\. chgst } alias AUTORENAMEmcommand { if (match($0 ON OFF)) {/up_it AUTORENAME $0} pecho AutoRenaming of existing offered files is $AUTORENAME\. chgst } alias NOISEmcommand { if (match($0 ON OFF)) {/up_it NOISE $0} pecho XDCC Noise is $NOISE\. chgst } alias OVERWRITEmcommand { if (match($0 ON OFF)) {/up_it OVERWRITE $0} pecho Overwrite existing files \(no prompting\) is $OVERWRITE\. } alias ULDIRmcommand { if ([$0]) {^assign newdir $0} {^assign newdir $"[E/X] New upload directory: " } if ([$newdir]!=[]) { ^assign olddir $W ^cd $newdir ^assign uploaddir $W ^cd $olddir ^assign -olddir } ^assign -newdir pecho Upload directory: $uploaddir\. } alias DLDIRmcommand { if ([$0]) {^assign newdir $0} {^assign newdir $"[E/X] New download directory: " } if ([$newdir]!=[]) { ^assign olddir $W ^cd $newdir ^assign downloaddir $W ^cd $olddir ^assign -olddir } ^assign -newdir pecho Download directory: $downloaddir\. } alias xdccecho if ([$NOISE] == [ON]) {/pecho $0-} alias x_file { ^assign TMP $0 if (rindex(/ $TMP)) { @ function_return = right(${@TMP-rindex(/ $0)+1} $0) } { @ function_return = [$0] } } alias adddccrequest { @ GETCOUNT = GETCOUNT + 1 @ ARRAYFILEGET[$GETCOUNT] = [$0] @ ARRAYNICKGET[$GETCOUNT] = [$1] chgst } alias CLOSEmcommand { if (GETCOUNT > 0) { @ TMPNICK = [] ^assign TMPNICK $"[E/X] Nick to remove get files (* for all): " if ([$TMPNICK]) { if ([$TMPNICK] == [*]) { @ GETCOUNT = 0 foreach ARRAYFILEGET XX { //^dcc close get $ARRAYNICKGET[$XX] } chgst pecho All files removed from get list. } { @ COUNT8 = 1 @ COUNT9 = 1 @ COUNT10 = GETCOUNT while (COUNT9 <= COUNT10) { if ([$ARRAYNICKGET[$COUNT9]] != [$TMPNICK]) { @ ARRAYFILEGET[$COUNT8] = [$ARRAYFILEGET[$COUNT9]] @ ARRAYNICKGET[$COUNT8] = [$ARRAYNICKGET[$COUNT9]] @ COUNT8 = COUNT8 + 1 } { //^dcc close get $TMPNICK @ GETCOUNT = GETCOUNT - 1 } @ COUNT9 = COUNT9 + 1 } chgst } } {} } { pecho There are no pending files. } } alias DIRmcommand { @ TMPVAR = [] ^assign TMPVAR $"[E/X] Dir: " if ([$getdir()] == [OK]) { @ COUNT8 = 1 pecho Length File while (COUNT8 <= FILECOUNT) { pecho $[10]FILELENG[$COUNT8] $FILELIST[$COUNT8] @ COUNT8 = COUNT8 + 1 } } } alias GETmcommand { if (GETCOUNT > 0) { @ TMPNICK = [] ^assign TMPNICK $"[E/X] Nick to get files (* for all): " if ([$TMPNICK]) { if ([$TMPNICK] == [*]) { @ GETCOUNT = 0 foreach ARRAYFILEGET XX {//^dcc get $ARRAYNICKGET[$XX] $ARRAYFILEGET[$XX]} chgst pecho All files taken from get list. } { @ COUNT8 = 1 @ COUNT9 = 1 @ COUNT10 = GETCOUNT pecho Getting all files offered from $TMPNICK\. while (COUNT9 <= COUNT10) { if ([$ARRAYNICKGET[$COUNT9]] != [$TMPNICK]) { @ ARRAYFILEGET[$COUNT8] = [$ARRAYFILEGET[$COUNT9]] @ ARRAYNICKGET[$COUNT8] = [$ARRAYNICKGET[$COUNT9]] @ COUNT8 = COUNT8 + 1 } { //^dcc get $TMPNICK $ARRAYFILEGET[$COUNT9] @ GETCOUNT = GETCOUNT - 1 } @ COUNT9 = COUNT9 + 1 } chgst } } {} } { pecho There are no files offered. } } alias GLISTmcommand { if (GETCOUNT > 0) { @ TMPNICK = [] ^assign TMPNICK $"[E/X] Nick to list pending files (* for all): " if ([$TMPNICK]) { @ COUNT11 = 1 pecho Nick File while (COUNT11 <= GETCOUNT) { if (match($TMPNICK $ARRAYNICKGET[$COUNT11])) { pecho $[9]ARRAYNICKGET[$COUNT11] $ARRAYFILEGET[$COUNT11] } {} @ COUNT11 = COUNT11 + 1 } } {} } { pecho There are no pending files. } } alias LOADmcommand { if ([$0]) { eval /pecho Loading XDCC Offer file.... @ OLDNUM = TOTPACK @ LOAD_ERROR = [NO] @ LINECOUNT = 0 @ COUNT12 = [desc comment] ^on exec_error "load_files *" { pecho Error: $1- @ LOAD_ERROR = [YES] } ^on ^exec "load_files *" add_line $$1- ^exec -name load_files cat $0 ^wait %load_files if ([$LOAD_ERROR] == [NO]) { eval /pecho Checking file... @ COUNT = 1 while (COUNT <= LINECOUNT) { add_file $XDCCFILELINE[$COUNT] @ COUNT = COUNT + 1 } if (ARRAYTOTF[$TOTPACK] == 0) { @ TOTPACK = TOTPACK - 1 } {} chgst } {} if ([$LOAD_ERROR] == [NO]) { eval /pecho Offer file loaded correctly.} { @ TOTPACK = OLDNUM } } { if ([$OFFERFILE]!=[]) { /pecho Default: loading $OFFERFILE\... /loadmcommand $OFFERFILE } {/pecho No such file. Try /XDCC HELP LOAD.} } } alias SAVEmcommand { if ([$0]) { /pecho Saving file... @ TEMP1 = [$1-] @ SAVE_ERROR = [NO] @ TEMP2 = [] @ COUNT = 0 @ LINECOUNT = 0 if ([$1]) { while (word($COUNT $TEMP1)) { if ([$[1]word($COUNT $TEMP1)] != [#]) { /pecho Error: $word($COUNT $TEMP1) is not a valid pack format. @ SAVE_ERROR = [YES] } { @ TEMP = word($COUNT $TEMP1) @ NUM = right(${@TEMP-1} $TEMP) if (NUM > TOTPACK) { /pecho Error: #$NUM does't exist. @ SAVE_ERROR = [YES] } { @ TEMP2 = [$TEMP2] ## [ $NUM] } } @ COUNT = COUNT + 1 } } { while (COUNT < TOTPACK) { @ COUNT = COUNT + 1 @ TEMP2 = [$TEMP2] ## [ $COUNT] } } if ([$SAVE_ERROR] != [YES]) { @ COUNT = 0 @ SAVE_ERROR = [NO] while (word($COUNT $TEMP2)) { add_line Comment Pack $COUNT add_line desc $ARRAYDESC[$word($COUNT $TEMP2)] @ COUNT1 = 0 while (COUNT1 < ARRAYTOTF[$word($COUNT $TEMP2)]) { @ COUNT1 = COUNT1 + 1 add_line files $ARRAYFILE[$word($COUNT $TEMP2)][$COUNT1] } @ COUNT = COUNT + 1 } ^on exec_error "save_xdcc_file *" { pecho Error: $1- @ SAVE_ERROR = [YES] } @ COUNT = 0 while (COUNT < LINECOUNT) { @ COUNT = COUNT + 1 ^exec -name s_xdcc_f echo $XDCCFILELINE[$COUNT] >> $0 wait %s_xdcc_f } if ([$SAVE_ERROR] = [NO]) { /pecho File saved correctly.} {} } {} } { /pecho What filename? Try /XDCC HELP SAVE. } } alias add_line { @ LINECOUNT = LINECOUNT + 1 @ XDCCFILELINE[$LINECOUNT] = [$0-] } alias add_file { if (match($0 $COUNT12)) { if ([$0] == [desc]) { @ OLDNUM = TOTPACK if ((TOTPACK >= 0) && (ARRAYTOTF[$TOTPACK] == 0)) {} { @ TOTPACK = TOTPACK + 1 } @ ARRAYDESC[$TOTPACK] = [$1-] @ ARRAYTOTF[$TOTPACK] = 0 @ COUNT12 = [files comment] } { if ([$0] == [files]) { @ COUNT12 = [desc files comment] @ TMPVAR = [$1-] if ([$getdir()] == [OK]) { @ COUNT13 = 1 while (COUNT13 <= FILECOUNT) { @ ARRAYTOTF[$TOTPACK] = ARRAYTOTF[$TOTPACK] + 1 @ ARRAYFILE[$TOTPACK][$ARRAYTOTF[$TOTPACK]] = [$FILELIST[$COUNT13]] @ ARRAYLENG[$TOTPACK][$ARRAYTOTF[$TOTPACK]] = [$FILELENG[$COUNT13]] @ COUNT13 = COUNT13 + 1 } } {} } {} } {} } { @ LOAD_ERROR = [YES] pecho Error loading offer file on line: pecho [$COUNT] $0- pecho First word on line isn't [$COUNT12]\. @ COUNT = LINECOUNT } } ### Miscellaneous Junk alias back setback alias gone { sf_assigning @ byecount = [$rand($byenum)] ^assign gone $(sf$byecount) setaway $gone } alias bye { sf_assigning @ byecount = [$rand($byenum)] ^assign gone $(sf$byecount) signoff $gone } alias sf_assigning { ^assign byenum 68 @ sf1=[Sorrow paid for valor is too much to recall.] @ sf2=[Shun words of the bible, we need implements of war.] @ sf3=[Destiny, the crooked schemer, says the dead shall rise again.] @ sf4=[Demonic link?] @ sf5=[bad, Bad, REAL BAD link?] @ sf6=[Missing link?] @ sf7=[Chain link?] @ sf8=[Where do we go from here?] @ sf9=[And should we really care?] @ sf10=[The end is finally here. God have mercy!] @ sf11=[Sweet taste of vindication, It turns to ashes in your mouth.] @ sf12=[If you're fighting to live, It's ok to die!] @ sf13=[The answer to your question is...Welcome to tomorrow!] @ sf14=[Blue sky, Black death, I'm off to meet my maker!] @ sf15=[Jump or die!] @ sf16=[Assassin in stealth, Assailant from hell.] @ sf17=[Part Bionic, and Organic...Not a Cyborg.] @ sf18=[Feeling claustrophobic, like the walls are closing in.] @ sf19=[Blood stains on my hands and I don't know where I've been.] @ sf20=[http://darkstar.frop.org] @ sf21=[Darkstar owns you, and you know it.] @ sf22=[Fucked up link?] @ sf23=[Funky link?] @ sf24=[I'm in trouble for the things I haven't got to yet.] @ sf25=[I'm sharpening the axe and my palms are getting wet.] @ sf26=[Sweating Bullets!] @ sf27=[My icy fingers claw your back...here I come again!] @ sf28=[No escaping pain, you belong to me.] @ sf29=[Clinging on to life, by the skin o' my teeth.] @ sf30=[I need a ride to the morgue, that's what 911 is for.] @ sf31=[That that doesn't kill me, only makes me stronger.] @ sf32=[Born from the dark, in the black cloak of night.] @ sf33=[Set the world Afire!!!] @ sf34=[They said it'd never come, we knew it was a lie.] @ sf35=[All forms of life die now, the humans all succumb.] @ sf36=[Time to kiss your ass goodbye, the end has just begun.] @ sf37=[No time to change your fate, no time left, it's too late.] @ sf38=[And if it comes, the living will envy the dead!] @ sf39=[No one will be left to prove the humans existed.] @ sf40=[We all live on one planet and it will all go up in smoke.] @ sf41=[To bad they couldn't see this lethal energy.] @ sf42=[And now the final scene, a global darkening...] @ sf43=[Einstein said `We'll use rocks on the other side'.] @ sf44=[Oh shit, cops at my door!1!!@!!1!1!@!@@1!!] @ sf45=[Badd link?] @ sf46=[Supercalifragilisticexpealidotious link?] @ sf47=[Cactus?] @ sf48=[No Survivors!!!!!! Set the World Afire!!!!] @ sf49=[I walk, I walk alone, into the promised land...] @ sf50=[There's a better place for me, but it's far, far away...] @ sf51=[Everlasting life for me, in a perfect world.] @ sf52=[But I gotta die first, please God send me on my way!] @ sf53=[You just laughed, ha ha, bitch.] @ sf54=[But the time has come when all things shall pass.] @ sf55=[This good thing passed away.] @ sf56=[Forgive me father, for I have sinned.] @ sf57=[I'm a child of the air, I'm a witch of the wind.] @ sf58=[Lie, steal and cheat, a real bad guy!] @ sf59=[I'm not a fish, I'm a man!] @ sf60=[Perhaps I'll try real life for awhile.] @ sf61=[Pull over, shithead, this is the cops!] @ sf62=[Rot in hell, it's time you know...to your master, off you go!] @ sf63=[/