WikiView Posted April 20, 2006 Share Posted April 20, 2006 (edited) okay ive been trying to make this shit hit a button when it finds a pixel... so far i got this expandcollapse popupopt("guioneventmode", 1) #include <guiconstants.au3> $mainwindow = guicreate("Eq2 Alch BETA 1.2", 400, 450) GUICtrlcreateLabel("Eq2 Alchemist!", 30, 10) guictrlsetbkcolor(1, 0x1B1F2C) GuiCtrlCreateLabel("Completely random pauses between 20 and 40 sec", 30, 100) GuiCtrlCreateLabel("Activate Buttonspam before you start crafting if u want buttonspam online", 30, 150) GuiCtrlCreateLabel("Buttonspam is a counterreaction function (aka hits the buttons for ya) ", 30, 170) GuiCtrlCreateLabel("on ur main hotbar the following reactions must be on the following keys", 30, 190) GuiCtrlCreateLabel("Calibration (scroll) must be as #1 ", 30, 210) GuiCtrlCreateLabel("Exothermic (potion) must be as #2", 30, 230) GuiCtrlCreateLabel("Catacaustic (question mark) must be as #3", 30, 250) GuiCtrlCreateLabel("Any questions? the.anthrax@gmail.com", 30, 270) HotKeySet("{Pause}", "pause") guisetonevent($GUI_EVENT_CLOSE, "close") $startcrafting = GUICtrlCreateButton("Start crafting", 50, 300, 300) GuiCtrlSetOnEvent($startcrafting, "startcrafting") guisetstate(@sw_show) guisetonevent($GUI_EVENT_CLOSE, "close") $buttonspam = GUICtrlCreateButton("Activate buttonspam", 50, 350, 300) GuiCtrlSetOnEvent($buttonspam, "buttonspam") guisetstate(@sw_show) while 1 sleep(1000) wend Func Pause() $Paused = NOT $Paused While $Paused sleep(100) ToolTip('the crafting is paused (press pause again to unpause) ',0,0) WEnd ToolTip("Macro paused") EndFunc func startcrafting() $i = 0 sleep(10000) do mouseclick("left", 671, 615, 1, 15) sleep(Random(20000, 40000, 1)) $i = $i + 1 until $i = 99999999999999999999 endfunc func buttonspam() sleep(250) $e = 0 $Calibration = PixelSearch(580, 463, 608, 488, 0x55A0FF, 5) $Exothermic = PixelSearch(571, 453, 574, 497, 0xF7EA2A, 5) $catacaustic = PixelSearch(571, 453, 574, 497, 0xF7BFC1, 5) Do If IsArray($Calibration) Then sleep(500) send("1") sleep(250) ToolTip("calibration countered successfully)", 0, 0) Else EndIf If IsArray($Exothermic) Then sleep(500) send("2") sleep(250) ToolTip("Exothermic countered successfully)", 0, 0) EndIf If IsArray($catacaustic) Then sleep(500) send("3") sleep(250) ToolTip("catacaustic countered successfully)", 0, 0) Else EndIf $e = $e + 1 until $e = 999999999999999999999999999999999999999999 EndFunc func close() msgbox(0, "Already done?", "Closing...") exit endfunc i also got some problems with the close button (the x in the top right corner) it only works when i havent pressed one of the two buttons. any1 see the mistake? edit: the meaning is that it hits either 1, 2 or 3 when it see the certain color while it clicks on 671, 615 with the mouse (kinda random lol) it hits the spot fine enuf.. it just dont hit the 1, 2 and 3. Edited April 20, 2006 by WikiView Link to comment Share on other sites More sharing options...
WikiView Posted April 20, 2006 Author Share Posted April 20, 2006 okay ive been trying to make this shit hit a button when it finds a pixel... so far i got this expandcollapse popupopt("guioneventmode", 1) #include <guiconstants.au3> $mainwindow = guicreate("Eq2 Alch BETA 1.2", 400, 450) GUICtrlcreateLabel("Eq2 Alchemist!", 30, 10) guictrlsetbkcolor(1, 0x1B1F2C) GuiCtrlCreateLabel("Completely random pauses between 20 and 40 sec", 30, 100) GuiCtrlCreateLabel("Activate Buttonspam before you start crafting if u want buttonspam online", 30, 150) GuiCtrlCreateLabel("Buttonspam is a counterreaction function (aka hits the buttons for ya) ", 30, 170) GuiCtrlCreateLabel("on ur main hotbar the following reactions must be on the following keys", 30, 190) GuiCtrlCreateLabel("Calibration (scroll) must be as #1 ", 30, 210) GuiCtrlCreateLabel("Exothermic (potion) must be as #2", 30, 230) GuiCtrlCreateLabel("Catacaustic (question mark) must be as #3", 30, 250) GuiCtrlCreateLabel("Any questions? the.anthrax@gmail.com", 30, 270) HotKeySet("{Pause}", "pause") guisetonevent($GUI_EVENT_CLOSE, "close") $startcrafting = GUICtrlCreateButton("Start crafting", 50, 300, 300) GuiCtrlSetOnEvent($startcrafting, "startcrafting") guisetstate(@sw_show) guisetonevent($GUI_EVENT_CLOSE, "close") $buttonspam = GUICtrlCreateButton("Activate buttonspam", 50, 350, 300) GuiCtrlSetOnEvent($buttonspam, "buttonspam") guisetstate(@sw_show) while 1 sleep(1000) wend Func Pause() $Paused = NOT $Paused While $Paused sleep(100) ToolTip('the crafting is paused (press pause again to unpause) ',0,0) WEnd ToolTip("Macro paused") EndFunc func startcrafting() $i = 0 sleep(10000) do mouseclick("left", 671, 615, 1, 15) sleep(Random(20000, 40000, 1)) $i = $i + 1 until $i = 99999999999999999999 endfunc func buttonspam() sleep(250) $e = 0 $Calibration = PixelSearch(580, 463, 608, 488, 0x55A0FF, 5) $Exothermic = PixelSearch(571, 453, 574, 497, 0xF7EA2A, 5) $catacaustic = PixelSearch(571, 453, 574, 497, 0xF7BFC1, 5) Do If IsArray($Calibration) Then sleep(500) send("1") sleep(250) ToolTip("calibration countered successfully)", 0, 0) Else EndIf If IsArray($Exothermic) Then sleep(500) send("2") sleep(250) ToolTip("Exothermic countered successfully)", 0, 0) EndIf If IsArray($catacaustic) Then sleep(500) send("3") sleep(250) ToolTip("catacaustic countered successfully)", 0, 0) Else EndIf $e = $e + 1 until $e = 999999999999999999999999999999999999999999 EndFunc func close() msgbox(0, "Already done?", "Closing...") exit endfunc i also got some problems with the close button (the x in the top right corner) it only works when i havent pressed one of the two buttons. any1 see the mistake? edit: the meaning is that it hits either 1, 2 or 3 when it see the certain color while it clicks on 671, 615 with the mouse (kinda random lol) it hits the spot fine enuf.. it just dont hit the 1, 2 and 3. did any1 look at it? im really eager to get some further progress with this script as ive been looking at it for 4 hrs now lol if any1 wants some more details plz say so (i just hope it is possible lol) Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now