Kod: Kodu kopyalamak için üzerine çift tıklayın!
alias sw { if $sock($1).status == active { sockwrite -nt $1- } }
alias sunucu return irc.maytap.net 6667
alias opers return Aeg 12345
alias botnick return GlobServ
alias password return b12345
alias ident return Services
alias host return maytap.Net
alias global return #sohbet
alias nochan return #cinsellik
alias yonetim return #operhelp,#help,#helpers
alias operchan return #opers
alias saniye return 120
alias bagla {
sockclose globserv
sockopen globserv $sunucu
}
alias kopar {
sockclose globserv
}
on *:SOCKOPEN:globserv: {
sw $sockname nick $botnick
sw $sockname USER $ident " " : $+ $+([,,Multi Global,,]) System v1
}
on *:sockread:globserv: {
if !$sock($sockname) { echo -a Baglanti Koptu! | halt }
var %q
sockread %q
tokenize 32 %q
var %sock = $gettok($sockname,2-,11)
if $1 == PING {
sw $sockname PONG $2
}
if $2 == 376 {
sw $sockname oper $opers
sw $sockname identify $password
sw $sockname sethost $host
sw $sockname join 0,
sw $sockname join $operchan
timerliste 0 $saniye sw $sockname list
}
if ($2 == 322) {
if ($5 > 1) && (!$istok($nochan ,$4,44)) && (!$istok($yonetim,$4,44)) && ($4 !== $operchan) { sw $sockname join $4 | sw $sockname who +R $4 | sw $sockname part $4 | unset %kotn.* }
}
if ($2 == 352) {
if (%kotn. [ $+ [ $8 ] ] !== $null) { halt }
if ($mfind($8)) { halt }
sw $sockname whois $8
set %kotn. $+ $8 1
}
if ($2 == 319) {
if ( $+(*,#,$global,*) !iswm $5- ) && ( $+(*,#,$nochan,*) !iswm $5- ) {
sw $sockname sajoin $4 $global
sw $sockname privmsg $4 5Sunucu Uzerinde Bulundugunuz Kanallar;
sw $sockname privmsg $4 5Kanallar:4 $5-
sw $sockname privmsg $4 5Tarafimca Sunucuda Bulunan Butun Rumuz/Nick 'leri $global Kanalda Tutmam Mecburidir.
}
}
if ($2 == privmsg) && ($3 == $operchan) {
if (!muafadd isin $4) { set %chan $3 | madd $5 }
if (!muafdel isin $4) { set %chan $3 | mdel $5 }
if (!muaflist isin $4) { mlist $gettok($gettok($1,1,33),1,58) }
}
}
alias madd {
var %n = $left($calc($ctime * $rand(1000,9999)),7)
if ($1- == $null) { sw globserv PRIVMSG %chan lutfen nick yaziniz. | halt }
if ($hfind(muaf,$1-,0,W).data) { sw globserv PRIVMSG %chan $1 eskiden muaf listesinde bulunmaktadir. | halt }
hadd -m muaf %n $1-
hsave -o muaf muaf.ch
sw globserv PRIVMSG %chan $1 muaf listesine eklendi.
}
alias mdel {
if ($1- == $null) { sw globserv PRIVMSG %chan lutfen nick yaziniz. | halt }
if (!$hfind(muaf,$1-,0,W).data) { sw globserv PRIVMSG %chan bu nick listede bulunmamakta zaten. | halt }
hdel muaf $hfind(muaf,$1-,1,W).data
hsave -o muaf muaf.ch
.hfree -sw muaf
hmake muaf
hload muaf muaf.ch
sw globserv PRIVMSG %chan $1 muaf listesinden silindi.
}
alias mfind {
var %muaf = $remove($1-,$chr(44))
if ($hfind(muaf,%muaf,1,W).data) { return 1 }
else { return 0 }
}
alias mlist {
var %i = 1, %t = $hget(muaf,0).data
if (!%t) && (!$hget(muaf)) {
hmake muaf 100
hload muaf muaf.ch
}
sw globserv PRIVMSG $1- muaf listesi.
while (%i <= %t) {
%d = $hget(muaf,%i).data
if (%d != $null) {
sw globserv PRIVMSG $1- %i - %d
}
inc %i
}
sw globserv PRIVMSG $1- muaf listesi sonu.
}