Can someone help me optimize my script

10/29/2017 15:07 edmer#1
Well, this is my first bot made in autoit .. so I'm very nooob I've asked for a lot of help here to make it work hahaha ... and well up to now I've achieved a lot of verdd .. but I see that my bot sometimes gets a little heavy: / or every time he works slower or with problems: / ... when using func pause I have to give him several times to grab him and things like that ... sometimes he starts to make my keyboard deconfigure and write in pure capital letters while they are deactivated ... someone could help me optimize it a bit ... And thank you very much :)


pliss and ty again to all !!
10/29/2017 21:14 elmarcia#2
I won't give u all the code because u won't learn anything, but i will give u some tips to start.

Vars u use in all your code should be global, those variables can be accessed and changed in any function, local ones will only be accesible inside a function

Caution with those while loops, you are overusing them, and you can't pause the bot anymore.


Here is what should do, instead of 10 loops use flags, u can also make code pretier with some extra functions


Example of simple bot script with image search
10/30/2017 11:49 edmer#3
Thank you brother ... thank you very much for your answer, as I said I am very new making bots and more using autoit ... I understand a little what you tell me but I do not fully understand it if you could leave me a little more explanation you could help even more ... please and I thank you ... and if I also appreciate that you do it in a way that I can learn but I do not understand much of the final how to solve everything hahaha !! Sorry ... and again thanks to everyone who wants to help.