everclear — File Browser

everclearv1.1 / everclearv1.1 / Scripts / ec11a1 / system / events.mrc

events.mrc — 10.61 KB — Download this file

on 1:join:#:{
  if ($nick == $me) { echo -a $join.me($chan) | set %who.temp yes | who $chan | halt }
  echo $chan $join.norm($chan,$nick,$address) | colornames $chan
  if (($ialchan($address($nick,2),$chan,2) != $null) && (%clonedet == on)) clonejoin $address($nick,2) $chan
  set %tempauto $readini user.ini auto-op $address($nick,3)
  if ((%tempauto == yes) && ($me isop $chan)) { mode $chan +o $nick | .notice $nick $logo Auto-op }
  set %tempauto $readini user.ini auto-v $address($nick,3)
  if ((%tempauto == yes) && ($me isop $chan)) { mode $chan +v $nick | .notice $nick $logo Auto-Voice }
  set %tempauto $readini user.ini shit $address($nick,3)
  if ((%tempauto == yes) && ($me isop $chan)) {
    set %tempauto $readini user.ini shit.reason $address($nick,3)
    ban $chan $nick 3 | kick $chan $nick shitlisted: $+ %tempauto
  }
  unset %temp*
}
on 1:start:{
  .debug on
  if ($exists(flood.ini)) .remove flood.ini | everclear
  titlebar $logo - http://kmv.simplenet.com/index1.html
}
on 1:connect:.timer50 0 1 1sec | autojoin | stats.me
on 1:disconnect:titlebar $logo Disconnected from $server @[ $+ $atime $+ ] ( $+ $adate $+ )
on 1:part:#:echo $chan $part.norm($chan,$nick,$address) | halt
on 1:quit:set %i 0 | :loop | inc %i | if (%i > $comchan($nick,0)) halt | echo $comchan($nick,%i) $quit.norm($nick,$address,$1-) | goto loop
raw 301:*:eecho $whois.aw($3-) | halt
raw 311:*:{
  eecho $whois.t($2) | eecho $whois.n($2)
  eecho $whois.a($1-) | eecho $whois.rn($6-) | halt
}
raw 312:*:eecho $whois.s($3) | halt
raw 313:*:eecho $whois.io | halt
raw 317:*:eecho $whois.i($3) | eecho $whois.l($4) | halt
raw 318:*:eecho $whois.e($2) | halt
raw 319:*:eecho $whois.c($3-) | halt
raw 401:*:eecho $whois.no1($2) | eecho $whois.no2($2) | halt
raw 402:*:eecho $whois.no1($2) | eecho $whois.no2($2) | eecho $whois.no3($2) | halt
alias eecho if ($1- == $null) goto end | echo -a $1- | :end
raw 352:*:if (%who.temp == yes) { halt }
raw 315:*:if (%who.temp == yes) { unset %who.temp | halt }
raw 366:*:colornames $2 | endnames $2
on 1:op:#:colornames $chan
on 1:deop:#:colornames $chan
on 1:voice:#:colornames $chan
on 1:devoice:#:colornames $chan
on 1:serverop:#:{
  colornames $chan
  if (%serv-op == on) {
    if ($me isop $chan) { mode $chan -o $opnick | .notice $nick Server Op Protection $logo | echo 4 -a Server Op Protection initiated | halt }
    else echo 4 -a Server Op detected, You don't have ops.
  }
}
on 1:input:#:{
  if ($left($1,1) != /) {
    if (%nickcomp == on) { cs $nick-comp($1-) | halt }
    else { cs $1- | halt }
  }
  if ($remove($1,/) == whois) { whois $2 $2 | halt }
}
on 1:input:*:{
  if ($remove($1,/) == whois) { whois $2 $2 | halt }
}
raw 1:*:secho $raw.1($2-) | halt
raw 2:*:secho $raw.2($1-) | halt
raw 3:*:secho $raw.3($6-) | halt
raw 4:*:secho $raw.4($3-) | halt
raw 251:*:secho $raw.251($1-) | halt
raw 252:*:secho $raw.252($2) | halt
raw 253:*:secho $raw.253($2) | halt
raw 254:*:secho $raw.254($2) | halt
raw 255:*:secho $raw.255($1-) | halt
raw 331:*:eecho $raw.notopic | halt
raw 332:*:eecho $raw.topic($3-) | halt
raw 333:*:eecho $raw.topicset($3,$4) | halt
alias secho if ($1 == $null) goto end | echo -s $1- | :end
#http off
on 1:dns:{
  if ($iaddress == $null) { .disable #http | unset %temp.web* | echo 4 -a * Error : Server does not exist. | halt }
  .raw privmsg $me :DCC CHAT CHAT $longip($iaddress) 80 $+ 
  .disable #http | .auser http $me | .creq +m auto
}
#http end
on +http:chatopen:.creq -m ask | .msg = $+ $me GET %temp.webadd | window @Web Browser 0 0 700 600 terminal | echo @Web Browser *Begin Document* | titlebar @Web Browser - %temp.webaddress
on +http:chatclose:.ruser http $me | close -c $me | echo @Web Browser *End Document*
on +http:chat:*:webconvert $1-
on 1:input:@Send Mail:{
  if ($1- == done) {
    .raw privmsg $me :DCC CHAT CHAT $longip(%mail.pop3.ip) 25 $+ 
    auser sendmail $me | .creq +m auto | rline @Send Mail $line(@Send Mail,0)   | rline @Send Mail $calc($line(@Send Mail,0) - 1) Sending Mail...
    halt
  }
  iline @Send Mail $calc($line(@Send Mail,0) - 2)  $+ $1- | write temp.txt $1-
  sline @Send Mail $line(@Send Mail,0) | halt
}
on +checkmail:chatopen:{
  .creq -m ask | unset %mail.checking | .msg = [ $+ [ $me ] ] user %mail.user | unset %mail.use.number %mail.reply*
  .msg = [ $+ [ $me ] ] pass %mail.pass | echo @Check Mail Connected to Mail server, Checking Mail...
}
on +checkmail:chat:*:{
  if (%mail.checking == yes) {
    if ($1 == +ok) { if ($exists(reply.txt)) { .remove reply.txt } | clear @Check Mail | halt }
    if ($1 == Date:) { halt }
    if ($1 == To:) { halt }
    if ($1 == From:) { set %mail.reply.from $2- }
    if ($1 == Subject:) { set %mail.reply.subject i'm bored }
    if ($1 == X-UIDL:) { halt }
    if ($1 == Status:) { halt }
    if ($1- == $null) { echo @Check Mail   | write reply.txt > | halt }
    if ($1- == .) { check-finished | halt }
    else { write reply.txt > $1- | echo @Check Mail  $+ $1- | halt }
  }
  set %temp +ok %mail.user has
  if (%temp isin $1-) {
    clear @Check Mail
    set %mail.totmessages $4
    if ($4 == 0) { echo @Check Mail You have No new messages on the server. | .msg = [ $+ [ $me ] ] quit | halt }
    if ($4 == 1) { echo @Check Mail You have 1 new message, press [F1] to view it, press [F10] to quit. | halt }
    echo @Check Mail You have $4 new messages, press [F(N)] to view the message (N being the number of the message you want to view.), press [F10] to quit. | halt
  }
  set %temp has been deleted | if (%temp isin $1-) { clear @Check Mail | echo @Check Mail Message $3 has been Deleted }
}
on +checkmail:chatclose:.ruser checkmail $me | close -c $me
on +sendmail:chatopen:{
  .creq -m ask | .msg = [ $+ [ $me ] ] helo $ip | .msg = [ $+ [ $me ] ] mail from: %mail.e-mail
  .msg = [ $+ [ $me ] ] rcpt to: %mail.sending.to | .msg = [ $+ [ $me ] ] data
  .msg = [ $+ [ $me ] ] Date: $fulldate | .msg = [ $+ [ $me ] ] To: %mail.sending.to
  .msg = [ $+ [ $me ] ] From: " $+ $me $+ " < $+ %mail.e-mail $+ > | .msg = [ $+ [ $me ] ] Subject: %mail.subject
  .timer 1 3 send-mail
}
on +sendmail:chatclose:close -c $me | .ruser sendmail $me
#checkmailip off
on 1:dns:{
  if ($iaddress == $null) { unset %mail.pop3 | echo $remove($color1,) -a Error : Mail POP3 Server does not exist. | .disable #checkmailip | halt }
  else { set %mail.pop3.ip $iaddress | echo $remove($color1,) -a Mail POP3 Server set to %mail.pop3 $+ . | .disable #checkmailip | halt }
}
#checkmailip end
on 1:dns:{
  eecho $color1 $+ ÕÍÍÍÍÍÍÍÍÍÍÍÍÍÍ $+ $color2 $+ DNS $+ $color1 $+ ÍÍÍÍÍÍÍÍÍÍÍÍÍ͸
  eecho $color1 $+ ³ $+ $color2 Nick $color3 $+ : $+ $color2 $align(22,$nick) $color1 $+ ³
  eecho $color1 $+ ³ $+ $color2 IPÿÿ $color3 $+ : $+ $color2 $deci($color2,$color1,$align(22,$iaddress)) $color1 $+ ³
  eecho $color1 $+ ³ $+ $color2 Addy $color3 $+ : $+ $color2 $align(22,$naddress) $color1 $+ ³
  eecho $color1 $+ ÔÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍ;
}
on 1:text:*:?:{
  if (%away == yes) {
    if (%away.log == on) { write logs.txt $atime < $+ $nick $+ > $1- | .msg $nick I'm away : ( $+ %away.reason $+ ), MSG Saved. $logo  | halt }
    .msg $nick I'm Away : ( $+ $1- $+ ). $logo
  }
}
ctcp 1:page:{
  if (%away.pager == on) { write logs.txt Page : $nick at $atime ( $+ $1- $+ ) | .notice $nick your page has been recorded $logo | beep | halt }
  else .notice $nick My pager is not on right now.  $logo
}
on 1:text:*:#:{
  if ((%curse-kick == on) && ($me isop $chan) && ($nick !isop $chan)) cursecheck $chan $nick $1-
  if (%caps-kick == on) {
    if (($nick !isop $chan) && ($me isop $chan)) {
      unset %temp* | set %temp $remove($1-,$chr(32)) | set %i 0 | :loop | inc %i | if (%i > $len(%temp)) goto next1
      if (($asc($mid(%i,1,%temp)) >= 65) && ($asc($mid(%i,1,%temp)) <= 90)) { inc %temp.caps | goto loop }
      else goto loop | :next1
      if ((%temp.caps >= 10) && ($percent(%temp.caps,$len(%temp))  >= 75)) { kick $chan $nick Caps Kicker $logo | goto next }
    }
  }
  if ((%repeat-kick == on) && ($nick !isop $chan) && ($me isop $chan)) {
    set %temp $readini flood.ini repeat $nick | if (%temp == $1-) { kick $chan $nick Repeat kicker $logo | remini flood.ini repeat $nick | goto next }
    else writeini flood.ini repeat $nick $1-
  }
  :next
  if (%flood.pro.chan == on) { textfloodpro $nick $chan $1- }
}
on 1:action:*:#:{
  echo 13 $chan í $nick $1-
  if ((%repeat-kick == on) && ($nick !isop $chan) && ($me isop $chan)) {
    set %temp $readini flood.ini repeat $nick | if (%temp == $1-) { kick $chan $nick Repeat kicker $logo | remini flood.ini repeat $nick | goto next }
    else writeini flood.ini repeat $nick $1-
  }
  :next
  halt
}
on 1:ctcpreply:ping*:echo -a $front $color1 $nick $+ 's Ping Reply $color2 $+ : $+ $color1 $duration($calc($ctime - $2)) | halt
ctcp 1:xdcc:{
  if ($2 isnum) goto send
  if ($2 == list) {
    set %i 0 | if (%xdcc.1 == $null) { .notice $nick No XDCC Packs Created! | halt }
    .notice $nick (xdcc|usage:ctcp $me xdcc #n|open slots: $+ $calc(5 - $send(0)) $+ /5) | :adloop | inc %i | set %temp %xdcc. [ $+ [ %i ] ]
    if (%temp == $null) { .notice $nick (xdcc list complete| $+ $calc(%i - 1) files offered| $+ %xdccsent files sent) | halt }
    set %temp1 %xdcc. [ $+ [ %i $+ .desc ] ] | set %temp2 %xdcc. [ $+ [ %i $+ .dl ] ]
    .notice $nick $chr(35) $+ $align1(2,%i) ( $+ $ralign1(3,%temp2) $+ x| $+ $ralign1(9,$size($lof( %xdcc. [ $+ [ %i ] ] ))) $+ ) $ralign1(12,$nopath( %xdcc. [ $+ [ %i ] ] )) $+ : %temp1 | goto adloop
  }
  :send
  set %temp1 $remove($2,$chr(35)) | if ($send(0) >= 5) { .notice $nick No Open slots, please try again later. | halt }
  set %temp %xdcc. [ $+ [ %temp1 ] ] | if (%temp == $null) { .notice $nick Pack $2 does not exist. | halt }
  inc %xdccsent | dcc send $nick %temp | .notice $nick Sending you Pack $2 ( $+ $nopath( %xdcc. [ $+ [ %temp1 ] ] ) $+ )
  inc %xdcc. [ $+ [ %temp1 $+ .dl ] ]
}
on 1:filesent:*:notice $nick I successfully sent you $nopath($filename) @ $+ $chgcps($send($nick).cps) $+ kb/s
on 1:filercvd:*:notice $nick I successfully recieved $nopath($filename) from you @ $+ $chgcps($get($nick).cps) $+ kb/s
ctcp 1:version:.ctcpreply $nick version $logo - 1.1a1 Matt
raw 211:*:{
  if (($remove($right($2,5),]) isnum) && (. !isin $remove($right($2,5),]))) {
    if (%port.tot == $null) { set %port.tot $remove($right($2,5),]) | set %port.best $6 | set %port.best1 $remove($right($2,5),]) }
    set %port.tot %port.tot $+ , $remove($right($2,5),])
    if ($6 < %port.best) { set %port.best $6 | set %port.best1 $remove($right($2,5),]) }
    halt
  }
  halt
}
raw 219:*:{
  eecho $front Ports : %port.tot
  eecho $front Best Port : %port.best1 ( $+ %port.best bytes)
  unset %port.* | halt
}