Oki Doki. Where to start. First of all apologies if i have offended you in any way. Sorry!!!!
My intentions where totally different.
1. Dismantled your exe using Exe2Aut
2. Removed all the packaging and all the files from code. ( much better to keep them separate and distribute only by adding it to zip)
3. Removed about 500 unnecessary code lines. (globals / functions vars not in use) .
4. Re-write how program searches for image. started using _imagesearcharea instead of _imagesearch.
This is big one as it increased performance of all by 300% at least. Depending how big resolution of your monitor is.
Lets say you have 3 x 27" monitors running at 2560x1440. So program scans every pixel of 7680x1440. WOW that takes too much CPU raw power.
On top of that add that you scanning screen for loot icon / 1- 3 skills / plus break of the stun 6 pictures. At the end you end-up with 8-11 pictures scanning thorough every pixel of the 7680x1440 so many times that application stars using about 20% or more of CPU power on its own. Memory usage increases like crazy too.
using _imagesearcharea is not ideal solution too as not every user can set coordinates for specific skill or know what I am talking about.
But for these who do you could create option to scan only specific window or add ability to set coordinates in .ini file near keybinds
That would help so many users
One more thing would be nice to have is scale selection and tolerance.
ok now down to the code
Code:
If GUICtrlRead($cboxvaacumloot) = $gui_checked Then
Local $recyclevariable = _imagesearcharea("loot.bmp", 1, 1400, 767, 1519, 884, $x, $y, 70)
If $recyclevariable = 1 Then
Send($vlootkey)
$recyclevariable = 0
EndIf
EndIf
do not pay any attention to the coordinates I've added. It needs tweaking as it is too big region to scan.
one ting I noticed while playing medic that if both DualShock and Atomize are up sometimes one of them are not fired cause I am using setup then button pressed it is continuously casting spell.
Problem is that code just send key press and moves on to the next IF and and depending how fast it will do cycle it could missfire.
Warning not tested yet !!!!!!! : I am thinking to change if to while so it will keep pressing skill until it will be pressed. This way in theory we should have more missfires.
I might be total wrong all about this - you decide.
Break out of the stun so slow I am currently looking on the way to speed it up. Will let you know if I will find anything
By the way in ideal world the best way to write program like that would be not using _image search but use memory reading like
[Release] XLoot 32/64-bit Autolooter [Memory reading].
Memory reading would be so much faster and so much more effective.
I might find time to do something like that later next week.