IRCForumu.Net - Türkiye'nin IRC ve mIRC Kullanıcılarının Buluştuğu Forum

IRCForumu.Net - Türkiye'nin IRC ve mIRC Kullanıcılarının Buluştuğu Forum (https://www.ircforumu.net/)
-   Hazır Kodlar (https://www.ircforumu.net/hazir-kodlar/)
-   -   IP Koruması (https://www.ircforumu.net/hazir-kodlar/5290-ip-korumasi.html)

immortaL 09 Mart 2017 19:45

IP Koruması
 
Kod:

on *:start:{
  if (!$hget(ips)) { .hmake ips | .hload ips ips.mercy }
  if (!$hget(muafn)) { .hmake muafn | .hload .hload muafn.mercy muafn.mercy }
}
alias ips { if !$dialog(ips) { .dialog -ms ips ips } }
dialog ips {
  title "IP Koruması"
  size -1 -1 159 191
  option dbu
  list 1, 6 13 64 74, size
  text "  IP'ler", 2, 24 5 20 7
  text "  Muaf Nick'ler", 3, 102 5 36 8
  list 4, 88 13 64 74, size
  edit "", 5, 6 91 64 14
  button "IP Ekle", 6, 15 107 45 12
  edit "", 7, 88 91 64 14
  button "Muaf Nick Ekle", 8, 97 107 45 12
  text "    İşlemler", 9, 63 124 32 8
  button "Partall", 10, 7 135 35 15
  button "Gline", 11, 81 135 35 15
  button "Shun", 12, 44 135 35 15
  button "Ban Kick", 13, 118 135 35 15
  text "  Silmek istediginiz IP'i yada Nick'i üstüne cift tıklayarak Silebilirsiniz.", 14, -2 156 165 8
  button "KAPAT", 15, 47 167 65 15
  box "", 16, 2 -1 72 124
  box "", 17, 84 -1 72 124
  box "", 18, 4 129 152 25
  box "", 19, 44 162 71 23
}
on *:dialog:ips:*:*: {
  if $devent == init {
    var %:ips = 1 | while %:ips <= $hget(ips,0).item { .did -a $dname 1 $hget(ips,%:ips).item | inc %:ips }
    var %:muafn = 1 | while %:muafn <= $hget(muafn,0).item { .did -a $dname 4 $hget(muafn,%:muafn).item | inc %:muafn }
  }
  if $devent == sclick {
    if $did == 6 { if (*.* iswm $did(5)) { if $hget(ips,$did(5)) { return } | if !$hget(ips) { .hmake ips 100 | .write ips.mercy | return } | .hadd -ms ips $did(5) $rand(10,999) | .hsave -o ips ips.mercy | did -a $dname 1 $did(5) } }
    if $did == 8 { if $did(7) { if #* iswm $did(7)  || *.* iswm $did(7)  { return } | if !$hget(muafn) { .hmake muafn 100 | .write muafn.mercy | return } | if $hget(muafn,$did(7)) { return } | .hadd -ms muafn $did(7) $rand(10,9999) | .hsave muafn muafn.mercy | .did -a $dname 4 $did(7) } }
    if $did == 10 { if %:nick { .sajoin %:nick #0,0 | unset %:nick | unset %:ipp } }
    if $did == 12 { if %:nick { .shun %:nick - Sebep | unset %:nick | unset %:ipp } }
    if $did == 11 { if %:ipp {  gline $+(*@,%:ipp) - Sebep | unset %:ipp | unset %:nick } }
    if $did == 13 { if %:nick { var %:com = 1 | while %:com <= $comchan(%:nick,0) { ban -k $comchan(%:nick,%:com) %:nick Sebep | inc %:com } unset %:nick | unset %:ipp } }
    if $did == 15 { unset %:nick | unset %:ipp | .dialog -c $dname }
  }
  if $devent == dclick {
    if $did == 1 { .hdel ips $hfind(ips,$did(1).seltext,1,W).item | .hsave -o ips ips.mercy | .hload ips ips.mercy | .did -d $dname 1 $did(1).sel }
    if $did == 4 { .hdel muafn $hfind(muafn,$did(4).seltext,1,W).item | .hsave -o muafn muafn.mercy | .hload muafn muafn.mercy | .did -d $dname 4 $did(4).sel }
 
  }
}
on *:snotice:*Client connecting on port*:{
  if $hget(muafn,$9) { return }
  var %:ip = 1 | while %:ip <= $hget(ips,0).item { if $+($hget(ips,%:ip).item,*) iswm $token($token($10,2,64),1,41) { .ips | set %:nick $9 | set %:ipp $token($token($10,2,64),1,41) | break } | inc %:ip }
}



Tüm Zamanlar GMT +3 Olarak Ayarlanmış. Şuanki Zaman: 15:32.

Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.6.0
Copyright ©2005 - 2023 IRCForumu.Net - Tüm Hakları Saklıdır.