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
Using
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), 0x312018,1)
Instead of
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)
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.
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.