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/)
-   -   Deprem Anons: V1.0 (https://www.ircforumu.net/hazir-kodlar/4733-deprem-anons-v1-0-a.html)

immortaL 20 Ağustos 2016 22:46

Deprem Anons: V1.0
 
Kod:

/*
Deprem Anons: V1.0
V1.0 Bitim tarihi: 17/12/2008
Yazan: Alience
Çalıştırma komutu: /deprem
*/


on *:start: {
  var %rawquery = $depdll(Query,SELECT value FROM Options WHERE name='isactive';)
  if $regex(%rawquery,(^S_OK)) {
    if $depdll(FetchRow,1) == S_OK 1 {
      var %rawquery = $depdll(Query,SELECT value FROM Options WHERE name='period';), %period = $gettok($depdll(FetchRow,1),2,32), %pps = 1500
      if %period == 1 { %pps = 900 }
      elseif %period == 2 { %pps = 1500 }
      elseif %period == 3 { %pps = 1800 }
      elseif %period == 4 { %pps = 2700 }
      elseif %period == 5 { %pps = 3600 }
      elseif %period == 6 { %pps = 5400 }
      elseif %period == 7 { %pps = 7200 }
      elseif %period == 8 { %pps = 9000 }
      elseif %period == 9 { %pps = 10800 }
      elseif %period == 10 { %pps = 12600 }
      elseif %period == 11 { %pps = 14400 }
      elseif %period == 12 { %pps = 16200 }
      elseif %period == 13 { %pps = 18000 }
      elseif %period == 14 { %pps = 36000 }
      elseif %period == 15 { %pps = 43200 }
      else { %pps = 2700 }

      var %rawquery = $depdll(Query,SELECT value FROM Options WHERE name='lastupdate';), %lastupdate = $gettok($depdll(FetchRow,1),2,32)
      if %pps <= $calc($ctime - %lastupdate) { .deprem -l }
      else { .timerdeprem 1 $calc(%pps - ($ctime - %lastupdate)) /.deprem -l }
    }
  }
}

on *:sockopen:depremler: {
  unset %depremler-pre
  set %deprmeler-count 0
  sockwrite -nt $sockname GET /scripts/lst1.asp HTTP/1.0  $+ $crlf
  sockwrite -nt $sockname Accept: image/gif, image/x-xbitmap, image/jpeg, image/pjpeg, application/x-shockwave-flash, application/vnd.ms-excel, application/vnd.ms-powerpoint, application/msword, */*  $+ $crlf
  sockwrite -nt $sockname Referer: www.koeri.boun.edu.tr $+ $crlf
  sockwrite -nt $sockname Accept-Language: tr $+ $crlf
  sockwrite -nt $sockname Content-Type: application/x-www-form-urlencoded $+ $crlf
  sockwrite -nt $sockname Proxy-Connection: Keep-Alive $+ $crlf
  sockwrite -nt $sockname User-Agent: Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; SV1; .NET CLR 2.0.50727) $+ $crlf
  sockwrite -nt $sockname Host: www.koeri.boun.edu.tr $+ $crlf
  sockwrite -nt $sockname Pragma: no-cache $crlf $+ $crlf
}

on *:sockread:depremler: {
  var %get
  sockread %get
  if $regex(%get,) {
    set %depremtimer $ctime
    unset %depremler-pre
    sockclose $sockname

    var %options = $depdll(Query,SELECT * FROM options;), %period = $null, %fetched = $null, %lastupdate = $null, %ischeckbig = $null, %bigvalue = $null, %coordinatevalue = $null, %anounstype = $null, %floodprot = $null, %btype = $null, %bnum = $null
    var %fldfile = $qt($+($scriptdir,floodprotect.tmp))
    if $regex(%options,^S_OK) {
      var %i = $gettok(%options,2,32)
      while %i {
        var %options = $depdll(FetchRow, $+ %i $+ ;), %opt = $gettok(%options,2-,32)
        if $gettok(%opt,1,9) == ischeckbig { %ischeckbig = $gettok(%opt,2,9) }
        if $gettok(%opt,1,9) == period { %period = $gettok(%opt,2,9) }
        if $gettok(%opt,1,9) == bigvalue { %bigvalue = $iif($regex($gettok(%opt,2-,9),\.),$gettok(%opt,2-,9),$+($gettok(%opt,2-,9),.0)) }
        if $gettok(%opt,1,9) == coordinatevalue { %coordinatevalue = $gettok(%opt,2-,9) }
        if $gettok(%opt,1,9) == anounstype { %anounstype = $gettok(%opt,2,9) }
        if $gettok(%opt,1,9) == floodprot { %floodprot = $gettok(%opt,2,9) }
        if $gettok(%opt,1,9) == lastupdate { %lastupdate = $gettok(%opt,2,9) }
        dec %i 1
      }
    }
    if %period == 1 { %pps = 900 }
    elseif %period == 2 { %pps = 1500 }
    elseif %period == 3 { %pps = 1800 }
    elseif %period == 4 { %pps = 2700 }
    elseif %period == 5 { %pps = 3600 }
    elseif %period == 6 { %pps = 5400 }
    elseif %period == 7 { %pps = 7200 }
    elseif %period == 8 { %pps = 9000 }
    elseif %period == 9 { %pps = 10800 }
    elseif %period == 10 { %pps = 12600 }
    elseif %period == 11 { %pps = 14400 }
    elseif %period == 12 { %pps = 16200 }
    elseif %period == 13 { %pps = 18000 }
    elseif %period == 14 { %pps = 36000 }
    elseif %period == 15 { %pps = 43200 }
    else { %pps = 2700 }
    .timerdeprem 1 %pps /.deprem -l

    if %ischeckbig {
      if %coordinatevalue {
        %rawquery = $depdll(Query,SELECT * FROM Depremler WHERE ctime >= ' $+ %lastupdate $+ ' AND (MD >= %bigvalue OR ML >= %bigvalue OR MS >= %bigvalue $+ ) AND (yer LIKE ' $+ $chr(37) $+ $replace(%coordinatevalue,$chr(44),$chr(37) $+ ' OR yer LIKE ' $+ $chr(37)) $+ $chr(37) $+ ');)
      }
      else {
        %rawquery = $depdll(Query,SELECT * FROM Depremler WHERE ctime >= ' $+ %lastupdate $+ ' AND (MD >= %bigvalue OR ML >= %bigvalue OR MS >= %bigvalue $+ );)
      }
    }
    else {
      if %coordinatevalue {
        %rawquery = $depdll(Query,SELECT * FROM Depremler WHERE ctime >= ' $+ %lastupdate $+ ' AND (yer LIKE ' $+ $chr(37) $+ $replace(%coordinatevalue,$chr(44),$chr(37) $+ ' OR yer LIKE ' $+ $chr(37)) $+ $chr(37) $+ ');)
      }
      else {
        %rawquery = $depdll(Query,SELECT * FROM Depremler WHERE ctime >= ' $+ %lastupdate $+ ');)
      }
    }
    %i = $gettok(%rawquery,2,32)
    if %i > 0 {
      if %anounstype == 12 {
        if %floodprot {
          write -c %fldfile
          write %fldfile 4Depremler Anons: Kriterlere uygun %i deprem oldu
          write %fldfile $+(,$str($chr(160),3),Tarih,$str($chr(160),6),Saat,$str($chr(160),4),Büy,$str($chr(160),2),Tip,$str($chr(160),2),Yer,$str($chr(160),5))
        }
        else {
          amsg 4Depremler Anons: Kriterlere uygun %i deprem oldu
          amsg $+(,$str($chr(160),3),Tarih,$str($chr(160),6),Saat,$str($chr(160),4),Büy,$str($chr(160),2),Tip,$str($chr(160),2),Yer,$str($chr(160),5))
        }
      }
      else {
        echo 4 Depremler Anons: Kriterlere uygun %i deprem oldu
        echo $+(,$str($chr(160),3),Tarih,$str($chr(160),6),Saat,$str($chr(160),4),Büy,$str($chr(160),2),Tip,$str($chr(160),2),Yer,$str($chr(160),5))
      }
      while %i {
        %fetched = $gettok($depdll(FetchRow,%i),3-,9)
        %btype = $iif($gettok(%fetched,7,9) > 0,MD,$iif($gettok(%fetched,8,9) > 0,ML,MS))
        %bnum = $iif($gettok(%fetched,7,9) > 0,$v1,$iif($gettok(%fetched,8,9) > 0,$v1,-))
        if %anounstype == 12 {
          if %floodprot { write %fldfile %tmpdate $+($gettok(%fetched,1,9),$str($chr(160),2),$gettok(%fetched,3,9),$str($chr(160),2),%bnum ,$str($chr(160),2),%btype,$str($chr(160),2),$gettok(%fetched,2,9)) }
          else { amsg %tmpdate $+($gettok(%fetched,1,9),$str($chr(160),2),$gettok(%fetched,3,9),$str($chr(160),2),%bnum ,$str($chr(160),2),%btype,$str($chr(160),2),$gettok(%fetched,2,9)) }
        }
        else { echo %tmpdate $+($gettok(%fetched,1,9),$str($chr(160),2),$gettok(%fetched,3,9),$str($chr(160),2),%bnum ,$str($chr(160),2),%btype,$str($chr(160),2),$gettok(%fetched,2,9)) }
        dec %i 1
      }
    }
    if  %anounstype == 12 && $gettok(%rawquery,2,32) { if %floodprot && $chan(0) { .play -ap /depremfld $chan(1) %fldfile 500 } }
    .depdll Query UPDATE options SET value=' $+ $ctime $+ ' WHERE name='lastupdate';
  }
  if %depremler-pre {
    inc %deprmeler-count 1
    if %deprmeler-count >= 7 && %get != $null {
      var %tarihtmp = $gettok(%get,1,32), %tarih = $+($gettok(%tarihtmp,3,46),.,$gettok(%tarihtmp,2,46),.,$gettok(%tarihtmp,1,46))
      var %saat = $gettok(%get,2,32), %enlem = $gettok(%get,3,32), %boylam = $gettok(%get,4,32), %derinlik = $gettok(%get,5,32), %md = $iif($gettok(%get,6,32) == -.-,0,$v1), %ml = $iif($gettok(%get,7,32) == -.-,0,$v1), %ms = $iif($gettok(%get,8,32) == -.-,0,$v1), %yer = $gettok(%get,9-,32)
      if %yer != $null {
        if $depdll(Query,SELECT * FROM Depremler WHERE ctime=' $+ $ctime( $+ %tarih %saat $+ ) $+ ' AND yer=' $+ %yer $+ ';) == S_OK 0 0 {
          :regenerate
          var %randrow = $rand(11111,999999)
          if $depdll(Query,SELECT * FROM Depremler WHERE did= $+ %randrow $+ ;) == S_OK 0 0 {
            .depdll Query INSERT INTO Depremler VALUES(' $+ %randrow $+ ',' $+ $ctime( $+ %tarih %saat $+ ) $+ ',' $+ %tarih $+ ',' $+ %yer $+ ',' $+ %saat $+ ',' $+ %enlem $+ ',' $+ %boylam $+ ',' $+ %derinlik $+ ',' $+ %md $+ ',' $+ %ml $+ ',' $+ %ms $+ ');             
          }
          else { goto regenerate }
        }
      }
    }
  }
  if $regex(%get,
) { set %depremler-pre $true }
}

;depremdll fonksiyonları depdll.
alias depdll {
  var %dllpath = $qt($+($scriptdir,db.dll))
  ;kullanım bilgisi
  ;alias sdepdll return $dll($qt($+($scriptdir,db.dll)),$1,$iif($2- != $null,$2-,_))
  var %check = $dll($qt($+($scriptdir,db.dll)),Open,Deprems $shortfn($+($scriptdir,depremler.db))))
  if !$regex(%check,(S_OK|E_LABEL_IN_USE)) { echo $color(info text) *** Depremler: Dll dosya hatası oluştu! | halt }

  ;query kabul etmiyor??
  ;%check = $dll($qt($+($scriptdir,db.dll)),Query,Deprems BEGIN TRANSACTION;)


  %check = $dll($qt($+($scriptdir,db.dll)),$1,Deprems $2-)

  if $isid { return %check }
  elseif $show && !$isid { echo $color(info text) *** Depremler: %check }
}

alias deprem {
  if $1 == -l {
    if $sock(depremler) { sockclose depremler }
    sockopen depremler www.koeri.boun.edu.tr 80
  }
  else {
    if !$dialog(depremdlg) { dialog -ma depremdlg depremtable }
  }
}
alias depremfld { amsg $2- | echo -a $2- }

;dialog options
;start date: 31/10/2008
dialog depremtable {
  title "Deprem Anons v1.0"
  size -1 -1 200 140
  option dbu
  check "Deprem addonu açık", 1, 3 2 62 10
  combo 2, 3 14 53 50, size drop
  text " te/da bir güncelle", 3, 57 15 50 8
  box "Anonslar:", 4, 3 28 195 82
  check "MD/ML/MS den bir tanesi", 5, 7 35 69 10
  edit "", 6, 77 35 25 10
  text "den büyük ise.", 7, 103 36 37 8
  text "yer adlarında aşağıdakilerden biri geçiyor ise (birden çok yer adını virgül ile ayırınız örn: ad1,ad2) boş bırakırsanız heryerde geçerli sayılır:", 8, 7 46 186 14
  edit "", 9, 7 61 186 10
  check "Shell anons komutları açık", 10, 7 71 75 10
  radio "anonsları kişisel yap", 11, 7 86 59 10
  radio "anonsları kanallara yansıt", 12, 7 95 73 10
  check "Flood korumasını aktif et (tavsiye edilir)", 13, 3 111 107 10
  button "Tamam", 14, 161 127 37 12,ok
  button "İptal", 15, 123 127 37 12,cancel
  text "Deprem Addon v1.0 - ßy Alience (Halim) - 2008", 16, 2 130 116 8,disable
}

on *:dialog:depremdlg:*:*: {
  if $devent == init {
    did -a $dname 2 15 dakika
    did -a $dname 2 25 dakika
    did -a $dname 2 30 dakika
    did -a $dname 2 45 dakika
    did -a $dname 2 1 saat
    did -a $dname 2 1.5 saat
    did -a $dname 2 2 saat
    did -a $dname 2 2.5 saat
    did -a $dname 2 3 saat
    did -a $dname 2 3.5 saat
    did -a $dname 2 4 saat
    did -a $dname 2 4.5 saat
    did -a $dname 2 5 saat
    did -a $dname 2 10 saat
    did -a $dname 2 12 saat

    var %options = $depdll(Query,SELECT * FROM options;)
    if $regex(%options,^S_OK) {
      var %i = $gettok(%options,2,32)
      while %i {
        var %options = $depdll(FetchRow, $+ %i $+ ;), %opt = $gettok(%options,2-,32)
        if $gettok(%opt,1,9) == isactive && $gettok(%opt,2,9) { did -c $dname 1 }
        if $gettok(%opt,1,9) == period { did -c $dname 2 $gettok(%opt,2,9) }
        if $gettok(%opt,1,9) == ischeckbig && $gettok(%opt,2,9) { did -c $dname 5 }
        if $gettok(%opt,1,9) == bigvalue { did -ra $dname 6 $gettok(%opt,2-,9) }
        if $gettok(%opt,1,9) == coordinatevalue { did -ra $dname 9 $gettok(%opt,2-,9) }
        if $gettok(%opt,1,9) == isonshell && $gettok(%opt,2,9) { did -c $dname 10 }
        if $gettok(%opt,1,9) ==  anounstype { did -c $dname $gettok(%opt,2,9) }
        if $gettok(%opt,1,9) == floodprot && $gettok(%opt,2,9) { did -c $dname 13 }
        dec %i 1
      }
    }
    did $iif($did(1).state,-e,-b) $dname 2-13 | did $iif($did(1).state,-b,-e) $dname 16
    if $did(1).state { did $iif($did(5).state,-e,-b) $dname 6-7 }
  }
  elseif $devent == sclick {
    if $did == 1 { did $iif($did(1).state,-e,-b) $dname 2-13 | did $iif($did(1).state,-b,-e) $dname 16  }
    if $did == 5 { did $iif($did(5).state,-e,-b) $dname 6-7 }

    if $did == 14 {
      var %rawquery = $depdll(Query,SELECT value FROM Options WHERE name='lastupdate';), %lastupdate = $gettok($depdll(FetchRow,1),2,32)

      .depdll Query UPDATE options SET value=' $+ $did(1).state $+ ' WHERE name='isactive';
      .depdll Query UPDATE options SET value=' $+ $did(2).sel $+ ' WHERE name='period';
      .depdll Query UPDATE options SET value=' $+ $did(5).state $+ ' WHERE name='ischeckbig';
      .depdll Query UPDATE options SET value=' $+ $did(6) $+ ' WHERE name='bigvalue';
      .depdll Query UPDATE options SET value=' $+ $did(9) $+ ' WHERE name='coordinatevalue';
      .depdll Query UPDATE options SET value=' $+ $did(10).state $+ ' WHERE name='isonshell';
      .depdll Query UPDATE options SET value=' $+  $iif($did(11).state,11,12) $+ ' WHERE name='anounstype';
      .depdll Query UPDATE options SET value=' $+ $did(13).state $+ ' WHERE name='floodprot';


      if $did(2).sel == 1 { %pps = 900 }
      elseif $did(2).sel == 2 { %pps = 1500 }
      elseif $did(2).sel == 3 { %pps = 1800 }
      elseif $did(2).sel == 4 { %pps = 2700 }
      elseif $did(2).sel == 5 { %pps = 3600 }
      elseif $did(2).sel == 6 { %pps = 5400 }
      elseif $did(2).sel == 7 { %pps = 7200 }
      elseif $did(2).sel == 8 { %pps = 9000 }
      elseif $did(2).sel == 9 { %pps = 10800 }
      elseif $did(2).sel == 10 { %pps = 12600 }
      elseif $did(2).sel == 11 { %pps = 14400 }
      elseif $did(2).sel == 12 { %pps = 16200 }
      elseif $did(2).sel == 13 { %pps = 18000 }
      elseif $did(2).sel == 14 { %pps = 36000 }
      elseif $did(2).sel == 15 { %pps = 43200 }
      else { %pps = 2700 }
      if %pps <= $calc($ctime - %lastupdate) { .deprem -l }
      else { .timerdeprem 1 $calc(%pps - ($ctime - %lastupdate)) /.deprem -l }
    }
  }
  elseif $devent == edit && $did == 6 {
    if $regex($did(6),[^0-9\.]) {
      var %pos = $calc($did(6).selstart + 1)
      did -ra $dname 6 $regsubex($replace($did(6),$chr(44),.),[^0-9\.],$null) 
      did -c $dname 6 1 %pos %pos
    }
  }
}

on *:text:!deprem*:#: {
  if $regex($2-,^\x61\x62\x6F\x75\x74$) {
    var %rawfetch = $depdll(Query,SELECT value FROM options WHERE name='vx1';)
    if $regex(%rawfetch,^S_OK) { .msg $chan $gettok($depdll(FetchRow,1),2-,32) }
    return
  }
  var %rawquery = $depdll(Query,SELECT value FROM Options WHERE name='isactive';), %isactive = $gettok($depdll(FetchRow,1),2,32)
  var %rawquery = $depdll(Query,SELECT value FROM Options WHERE name='isonshell';), %shellactive = $gettok($depdll(FetchRow,1),2,32)
  if %isactive && %shellactive {
    if $regex($2,^(help|yardım)$) {
      if $regex($2-,^((help|yardım)\starih)$) {
        .msg $nick Deprem Anons V1.0 tarih'e göre arama yardımı:
        .msg $nick herhangi bir kanala !deprem tarih yazarak o tarihe göre arama yapabilirsiniz
        .msg $nick örnek: !deprem 10.12.2008
      }
      elseif $regex($2-,^((help|yardım)\s(büyük|>))$) {
        .msg $nick Deprem Anons V1.0 büyüklüğe'e göre arama yardımı:
        .msg $nick herhangi bir kanala !deprem >değer(2, 2.1, vs) yazarak bu gün'e ait belirtiğiniz büyüklükten MD,MS veya ML si büyük depremleri sıralayabilirsiniz.
        .msg $nick örnek: !deprem >3.2
        .msg $nick Belirli bir güne göre büyüklük aramak için: !deprem tarih ># şeklinde arama yapmalısınız.
        .msg $nick örnek: !deprem 10.12.2008 >3.0
      }
      elseif $regex($2-,^((help|yardım)\s(yer))$) {
        .msg $nick Deprem Anons V1.0 deprem yerine göre arama:
        .msg $nick herhangi bir kanala !deprem yer yazarak o yere ait depremleri sıralayabilirsiniz.
        .msg $nick örnek: !deprem yalova
        .msg $nick Belirli bir güne göre belirli yerde arama yapmak için: !deprem yalova tarih şeklinde arama yapmalısınız.
        .msg $nick örnek: !deprem yalova 07.12.2008
        .msg $nick Belirli bir güne göre belirli bir büyüklükte ve yere göre arama yapmak için: !deprem yalova tarih şeklinde arama yapmalısınız.
        .msg $nick örnek: !deprem yalova 07.12.2008 >3
      }
      else {
        .msg $nick Deprem Anons V1.0 yardım:
        .msg $nick herhangi bir kanala !deprem yazarak bu güne ağit depremleri öğrenebilir
        .msg $nick !deprem yardım tarih yazarak tarih kullanarak
        .msg $nick !deprem yardım > yazarak büyüklüğe göre
        .msg $nick !deprem yardım yer yazarak depremin olduğu yere göre arama yapabilirsiniz.
      }
      return
    }
    if $regex($2,^>(([0-9]){1,})) {
      if $regex($2,([^0-9>\.])) { return QERR; $1- }
      var %num = $iif(. isin $remove($2,>),$v2,$+($v2,.0)), %rawquery = $depdll(Query,SELECT * FROM Depremler WHERE tarih=' $+ $replace($date,/,.) $+ ' AND (MD >= %num OR ML >= %num OR MS >= %num $+ );)
    }
    elseif $regex($2,([0-9]{1,2}\.[0-9]{1,2}\.[0-9]{2,4})) {
      if $3 == $null { var %num = $iif(. isin $remove($2,>),$v2,$+($v2,.0)), %rawquery = $depdll(Query,SELECT * FROM Depremler WHERE tarih=' $+ $replace($2,/,.) $+ ';) }
      else {
        if $regex($3,^>(([0-9]){1,})) {
          if $regex($3,([^0-9>\.])) { return QERR; $1- }
          var %num = $iif(. isin $remove($3,>),$v2,$+($v2,.0)), %rawquery = $depdll(Query,SELECT * FROM Depremler WHERE tarih=' $+ $replace($2,/,.) $+ ' AND (MD >= %num OR ML >= %num OR MS >= %num $+ );)
        }
        else { return QERR; $1- }
      }
    }
    elseif $regex($2,[a-zA-Z\-\(\)\*]) {
      if $2 == * { return QERR; Query too long }
      var %yer = $remove($2,query,select,inner,left,join,or,and)
      if $regex($3,^>(([0-9]){1,})) {
        if $regex($3,([^0-9>\.])) { return QERR; $1- }
        var %num = $iif(. isin $remove($3,>),$v2,$+($v2,.0)), %rawquery = $depdll(Query,SELECT * FROM Depremler WHERE yer LIKE ' $+ $replace(%yer,*,$chr(37)) $+ ' AND tarih=' $+ $replace($date,/,.) $+ ' AND (MD >= %num OR ML >= %num OR MS >= %num $+ );)
      }
      elseif $regex($3,([0-9]{1,2}\.[0-9]{1,2}\.[0-9]{2,4})) {
        if $4 == $null {
          var %num = $iif(. isin $remove($3,>),$v2,$+($v2,.0)), %rawquery = $depdll(Query,SELECT * FROM Depremler WHERE yer LIKE ' $+ $replace(%yer,*,$chr(37)) $+ ' AND tarih=' $+ $replace($3,/,.) $+ ';)
        }
        else {
          if $regex($4,^>(([0-9]){1,})) {
            if $regex($4,([^0-9>\.])) { return QERR; $1- }
            var %num = $iif(. isin $remove($4,>),$v2,$+($v2,.0)), %rawquery = $depdll(Query,SELECT * FROM Depremler WHERE yer LIKE ' $+ $replace(%yer,*,$chr(37)) $+ ' AND tarih=' $+ $replace($3,/,.) $+ ' AND (MD >= %num OR ML >= %num OR MS >= %num $+ );)
          }
          else { return QERR; $1- }
        }
      }
      else { %rawquery = $depdll(Query,SELECT * FROM Depremler WHERE yer LIKE ' $+ $replace(%yer,*,$chr(37)) $+ ';) }
    }
    else { var %rawquery = $depdll(Query,SELECT * FROM Depremler WHERE tarih LIKE ' $+ $replace($date,/,.) $+ ';) }

    var %i = $gettok(%rawquery,2,32)
    if %i >= 20 { .msg $chan 4 Aramanıza uygun 20'den fazla deprem olduğu için gösterilemiyor. | return }

    .msg $chan 4 Arama kriteriniz'e uygun %i deprem olmuş;
    .msg $chan $+(,$str($chr(160),3),Tarih,$str($chr(160),6),Saat,$str($chr(160),4),Büy,$str($chr(160),2),Tip,$str($chr(160),2),Yer,$str($chr(160),5))
    while %i {
      %fetched = $gettok($depdll(FetchRow,%i),3-,9)
      %btype = $iif($gettok(%fetched,7,9) > 0,MD,$iif($gettok(%fetched,8,9) > 0,ML,MS))
      %bnum = $iif($gettok(%fetched,7,9) > 0,$v1,$iif($gettok(%fetched,8,9) > 0,$v1,-))
      .msg $chan $+($gettok(%fetched,1,9),$str($chr(160),2),$gettok(%fetched,3,9),$str($chr(160),2),%bnum ,$str($chr(160),2),%btype,$str($chr(160),2),$gettok(%fetched,2,9))
      dec %i 1
    }
  }
}



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

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.