Edited...wrong post
Edited...wrong post
Hey i've always wanted the random sleep mod on this and have tried disecting from blacksacks script to here, but couldnt get it. I also tried your method but it doesnt seem to be sleeping on me. i tried doing 40%, just to test it out, and still see nothing. Any suggestions? How can i get this onto the status, so that way i can actually be convinced that its sleeping, and htat im not missing it wen im not watchign the screen.
Add this to the bottom of the script (or anywhere really)
Then insert anywhere you want to randomly take a break.Code:Func RandSleep($min = 5, $max = 45, $chance = 3) $randNum = Round(Random(1, 100)) If $Timer And $randNum <= $chance Then $sleepTime = Random($min * 1000, $max * 1000) GUICtrlSetData($lblStatus, "Status: Random Sleep - " & Round($sleepTime / 1000) & " secs") For $c = 0 To 10 Sleep($sleepTime / 10) Next EndIf EndFunc ;==>RandSleep
This says 10% chance to sleep for 5 to 30 seconds.Code:RandSleep(5, 30, 10)
Minimum Sleep Time in Seconds
Maximum Sleep Time in Seconds
Percent chance to trigger the sleep
This was code from Shims DH hunter script awhile back. You can also use RandSleep() anywhere for the default 5-45 seconds break @ 3% chance.
You will also have to add
to toggle this randomsleep on and off, or you can have it always on by changingCode:$Timer = True
toCode:If $Timer And $randNum <= $chance Then
Code:If $randNum <= $chance Then
Last edited by Angrycoder; 07-18-2012 at 06:22 AM.
FIX FOR 1366x768 Salvaging / Searching / Selling
The pixel color of the SlotLine is different for 1366 x 768 than it is for 1980 x 1020. I actually found this out last night after several hours finding my own coords before Chance was able to fix the ratio conversions today.
I couldnt find any Offset combination or line starting points, that would allow for the script to find the same pixel color as the 1980x1020 version, and i searched for a really long time ;p
UsingInstead ofCode:$SlotPixelLine = PixelSearch(Round(($slotLineTopX + $i * $offset) * $x_ratio), Round(($slotLineTopY + $j * $offset) * $y_ratio), Round(($slotLineBotX + $i * $offset) * $x_ratio), Round(($slotLineBotY + $j * $offset) * $y_ratio), 0x312018,1)
I have only done 1 sell with this new pixel color, but it sold every slot for me. I will run a few more rounds, and if all is good, then maybe chance can add in a special line for us using 1366x768.Code:$SlotPixelLine = PixelSearch(Round(($slotLineTopX + $i * $offset) * $x_ratio), Round(($slotLineTopY + $j * $offset) * $y_ratio), Round(($slotLineBotX + $i * $offset) * $x_ratio), Round(($slotLineBotY + $j * $offset) * $y_ratio), 0x2C1B14,1)
EDIT: Four full inventory runs later, on 2 different PCs, i can confirm this fixed all my issues 100%. It checked every cell, stashed correctly, salvaged correctly, vendored correctly.
I did not play around with using tolerances to try and use the same pixel colors as 1980 by 1020, because looking at side by side images the pixel colors really were not close, so changing the pixel color completely solved my issues. This is only for 1366x768. I would guess 1600x900 and other resolutions would have similar issues with pixel color.
I also added this post to Chancitys Wiz thread. Not sure if you make changes to this script LATM or just continually port the changes Chance makes.
Last edited by Angrycoder; 07-18-2012 at 05:41 AM.
Hi LATM,
I have a question here.
I'm confused about the time shown on the GUI.
According to your pic:
An open cellar run cost you 23.1 sec, and you have 487 open cellars. 23.1*487/3600 gives you around 3.12 hrs.![]()
A closed cellar run cost you 11.4 sec, and you have 501 closed cellars. 11.4*501/3600 gives you around 1.59 hrs.
So add them together, that is 4.71 hrs.
Compared to 7+44/60 = 7.73 hrs from your GUI, it's missing 3.02 hrs. Is that the time for [loading + analysing items + selling/stashing/salvage] ?
--------------------------------------------------------------------------------------
BTW, the total run number counting seems to be wrong. 487+501=988
--------------------------------------------------------------------------------------
A little piece of advice:
To get the most accurate GPH result, take screenshot right after the bot finishing a vendor run.
Last edited by tmxkn1; 07-18-2012 at 04:54 AM.
Dont know about the total time, maybe he has random sleeps or just manually paused it for extended periods of time at the main menu (not sure if the total time would keep running).
The total number of runs is correct, if he took the screen shot from Main Menu. Runs start at 0, not 1, and the cellar count and Run Number are updated at different times. Basically he did run number 0, found a cellar, the cellar count was updated when the script called for LeaveGame(), and the Run Number doesnt increase until ResumeGame() is called.
Thats insane for 7 hours...
ATM Im on 10 hours and 9 mins
with 507 OPEN and 506 Closed
9 Deaths * 8 Missed
and 3.71MIl accumlated at 365k Per HOur.... i dunno man and im at 334 GF Gear with 25% MS (Including the hot pursuit passive skill)
Is there something awfully wrong?
Last edited by tmxkn1; 07-18-2012 at 05:24 AM.
I would like to ask one thing.
- When my bot are going to vendor, the script just checks the upper row of items in my inventory. It doesn't even watch/point over the other items. That means every second run it are going to the vendor ATM :P What can I do? (If a resolve is in this thread somewhere, tell me to search!)
I run this in 1360x768 now, and I must say... Impressive work LATM. I really enjoy this.
Last edited by RogerHestlund; 07-18-2012 at 05:27 AM.
My opens are about 28.6s avg and closed are about 11.4s avg
NO Magic Find. um about 300 essences?
Um maybe its also my internet connection I have sometimes lag spikes (latency bar will go red), but usually and most likely it is on green like it is now. UM y dps is 19k.. IM using a 1k crossbow with 94 crit gem + 100 crit dmg gem.
Im mostly dieing in the area before entering the cellar. Say the cellar is closed and there are those ranged mobs. Even if i put trap down I still get hit and eventually kills me. Sometimes i casting time for town portal is too long and the mobs still kill me.