Aktuelle Zeit: 28. März 2024 12:04

Alle Zeiten sind UTC + 1 Stunde




 Seite 1 von 1 [ 1 Beitrag ] 
Autor Nachricht
 Betreff des Beitrags: /evaltime
BeitragVerfasst: 7. Juni 2008 16:45 
Administrator
Benutzeravatar

Registriert: 17. März 2008 13:32
Beiträge: 96
Wohnort: NRW, Germany
Be very careful if you wanna use that snippet with an alias that /notices or /msgs someone!
; Outputs you how long your custom identifier needs to return the result
; /evaltime [how often] <identifier>
; well it's not perfect but it helps optimizing scripts :P
alias evaltime {
  if ($1) {
    var %t = $iif($1 isnum,$1,1000),%x = %t,%ticks = $ticks,%str = $iif($1 isnum,$2-,$1-)
    while (%x) { editbox -a * %x evaluations left of $qt(%str) - Time gone: $calc($ticks - %ticks) ms | var %s = $(%str,2) | dec %x }
    editbox -a /evaltime $iif($1 isnum,$1) %str
    echo $color(info) -ag * Evaluating $+(",$chr(3),$color(action).dd,$chr(2),%str,$chr(15)," - %t times: $calc(($ticks - %ticks) / %t),ms/evaluating)
  }
  else { echo $color(info) -ag * Error: /evaltime [N] <identifier> }
}



_________________
one step closer to world domination
Cyberscripters Administrator/Founder
   
 
Beiträge der letzten Zeit anzeigen:  Sortiere nach  
 Seite 1 von 1 [ 1 Beitrag ] 

Alle Zeiten sind UTC + 1 Stunde


Wer ist online?

Mitglieder in diesem Forum: 0 Mitglieder


Du darfst keine neuen Themen in diesem Forum erstellen.
Du darfst keine Antworten zu Themen in diesem Forum erstellen.
Du darfst deine Beiträge in diesem Forum nicht ändern.
Du darfst deine Beiträge in diesem Forum nicht löschen.
Du darfst keine Dateianhänge in diesem Forum erstellen.

Suche nach:
Gehe zu:  

cron