Log summarizer
Code:
;Time Function
$trt = TimerDiff($t)
$hours = Floor((($trt / 1000) / 60) / 60)
$minutes = (($trt / 1000) / 60)
$sec = ($trt / 1000)
If $minutes > 60 Then
While $minutes > 60
$minutes -= 60
WEnd
EndIf
If $sec > 60 Then
While $sec > 60
$sec -= 60
WEnd
EndIf
;Gold Function
$mondelt = Number($mon) - Number($monold)
If $monstart = 0 Then $monstart = Number($mon) - $mondelt
;Item Function
$Totalpick = $LegendaryCount + $SetCount + $RareCount + $MagicCount
;Log Printer
Call("AddLog", "=============== iLog Zummarizer Start xD ===============")
Call("AddLog", 'Total Runtime: ' & $hours & ":" & Ceiling($minutes) & ":" & Ceiling($sec))
Call("AddLog", '=================================================')
Call("AddLog", 'Current Gold: ' & $mon & ", Total Gold Gain: " & Number($mon) - $monstart )
Call("AddLog", 'Gold Per Hour: ' & Ceiling((Number($mon) - $monstart) / ($trt / 3600000)) & ', Gold Per Trip: ' & Ceiling((Number($mon) - $monstart)/$run ))
Call("AddLog", 'Total Items Pick: ' & $Totalpick & ', Per Hour: ' & Ceiling(($Totalpick) / ($trt / 3600000)) & ', Per Trip: ' & $Totalpick / $cellarCount)
;enable these 4 lines below if you wants detailed item picks
;Call("AddLog", 'Total Items Pick: ' & $LegendaryCount & ', Per Hour: ' & Ceiling(($LegendaryCount) / ($trt / 3600000)) & ', Per Trip: ' & $LegendaryCount / $cellarCount)
;Call("AddLog", 'Total Items Pick: ' & $SetCount & ', Per Hour: ' & Ceiling(($SetCount) / ($trt / 3600000)) & ', Per Trip: ' & $SetCount / $cellarCount)
;Call("AddLog", 'Total Items Pick: ' & $RareCount & ', Per Hour: ' & Ceiling(($RareCount) / ($trt / 3600000)) & ', Per Trip: ' & $RareCount / $cellarCount)
;Call("AddLog", 'Total Items Pick: ' & $MagicCount & ', Per Hour: ' & Ceiling(($MagicCount) / ($trt / 3600000)) & ', Per Trip: ' & $MagicCount / $cellarCount)
;more stuff soon
Call("AddLog", 'Total Gems Pick: ' & $GemCount & ', Per Hour: ' & Ceiling(($GemCount) / ($trt / 3600000)) & ', Per Trip: ' & $GemCount / $cellarCount)
Call("AddLog", 'Total Tomes Pick: ' & $TomeCount & ', Per Hour: ' & Ceiling(($TomeCount) / ($trt / 3600000)) & ', Per Trip: ' & $TomeCount / $cellarCount)
Call("AddLog", '=================================================')
Call("AddLog", 'Cellar freq. (success/total runs): ' & $cellarCount & '/' & $run & ' = ' & ( $cellarCount / $run ) * 100 & ' %')
Call("AddLog", 'Trips Per Hour: ' & ((Number($run)) / ($trt / 3600000)) & ', Success runs: ' & $cellarCount & ', Fail runs: ' & Number($run) - $cellarCount )
Call("AddLog", '=================================================')
Call("AddLog", 'Deaths total: ' & $deathCount & ', Deaths Per Hour: ' & Number($deathCount) / ($trt / 3600000))
Call("AddLog", "=============== End of Log Summary ===============")
The code will summerize your bot session and put these values at the end of log file.
out put gonna be something like this
Code:
05/07/2012 07:43:00: =============== X Pressed Stopping Bot ===============
05/07/2012 07:43:00: =============== iLog Zummarizer Start xD ===============
05/07/2012 07:43:00: Total Runtime: 4:41:33
05/07/2012 07:43:00: =================================================
05/07/2012 07:43:00: Current Gold: 1847137, Total Gold Gain: 1730606
05/07/2012 07:43:00: Gold Per Hour: 370124, Gold Per Trip:
05/07/2012 07:43:00: Total Items Pick: 631, Per Hour: 135, Per Trip: 2.75545851528384
05/07/2012 07:43:00: Total Gems Pick: 407, Per Hour: 88, Per Trip: 1.77729257641921
05/07/2012 07:43:00: Total Tomes Pick: 22, Per Hour: 5, Per Trip: 0.0960698689956332
05/07/2012 07:43:00: =================================================
05/07/2012 07:43:00: Cellar freq. (success/total runs): 229/451 = 50.7760532150776 %
05/07/2012 07:43:00: Trips Per Hour: 96.4549839341157, Success runs: 229, Fail runs: 222
05/07/2012 07:43:00: =================================================
05/07/2012 07:43:00: Deaths total: 0, Deaths Per Hour: 0
05/07/2012 07:43:00: =============== End of Log Summary ===============
install instruction
Code:
Func Stop() ;to allow the script to stop @line 1383
<----------------------------------------------- Paste my code here
Exit
EndFunc ;==>Stop
more function coming soon hopefully :P
***havn't test with wizard hybrid code***