darksoltan Posted February 1, 2012 Share Posted February 1, 2012 Newbie here. I've rattled my brain and can't make this work. What I want to do is... once the mouse is in the area of a moving blue bar, autoit pixelsearches a fixed parameters of say 50height x 150length, relative to the position of the mouse, for the "blue bar", once it finds it, the mouse follows the moving bar indefinitely or until the bar disappears, while at the same time, and this is the hard part, clicking in a box right below the moving blue bar. Where the mouse is at all times, is irrelevant, as long as its able to click the box below the bar. This one has me stomped. Can anyone solve this? Blue Bar Example: http://imgur.com/4zkpe HotKeySet('{ESC}','_exit') sleep(2000) While 1 Global $mouse = MouseGetPos() $Coord = PixelSearch( $mouse[0]-150, $mouse[1]-45, $mouse[0]+150, $mouse[1]+45, 0x3F48CC, 5, 5) ; Search a blue bar near mouse position While @error = 0 MouseClick("left",$coord[0]+45,$coord[1]+40) MouseMove($coord[0], $coord[1], 1) $Coord = PixelSearch( $mouse[0]-40, $mouse[1]-40, $mouse[0]+40, $mouse[1]+40, 0x3F48CC, 5, 5) WEnd sleep(100) WEnd Func _exit() Exit EndFunc Link to comment Share on other sites More sharing options...
Beege Posted February 1, 2012 Share Posted February 1, 2012 I'd be very surprised if this was not for a game. Thats something not supported or allowed around here as stated in the rules. Assembly Code: fasmg . fasm . BmpSearch . Au3 Syntax Highlighter . Bounce Multithreading Example . IDispatchASMUDFs: Explorer Frame . ITaskBarList . Scrolling Line Graph . Tray Icon Bar Graph . Explorer Listview . Wiimote . WinSnap . Flicker Free Labels . iTunesPrograms: Ftp Explorer . Snipster . Network Meter . Resistance Calculator Link to comment Share on other sites More sharing options...
Moderators Melba23 Posted February 1, 2012 Moderators Share Posted February 1, 2012 darksoltan, You already have a thread running on exactly the same question - how about sticking to just the one at a time. And I share Beege's suspicions - please give me a reason in the other thread why I should not lock that one too. You have until 2200 UTC today. M23 Any of my own code posted anywhere on the forum is available for use by others without any restriction of any kind Open spoiler to see my UDFs: Spoiler ArrayMultiColSort ---- Sort arrays on multiple columnsChooseFileFolder ---- Single and multiple selections from specified path treeview listingDate_Time_Convert -- Easily convert date/time formats, including the language usedExtMsgBox --------- A highly customisable replacement for MsgBoxGUIExtender -------- Extend and retract multiple sections within a GUIGUIFrame ---------- Subdivide GUIs into many adjustable framesGUIListViewEx ------- Insert, delete, move, drag, sort, edit and colour ListView itemsGUITreeViewEx ------ Check/clear parent and child checkboxes in a TreeViewMarquee ----------- Scrolling tickertape GUIsNoFocusLines ------- Remove the dotted focus lines from buttons, sliders, radios and checkboxesNotify ------------- Small notifications on the edge of the displayScrollbars ----------Automatically sized scrollbars with a single commandStringSize ---------- Automatically size controls to fit textToast -------------- Small GUIs which pop out of the notification area Link to comment Share on other sites More sharing options...
Recommended Posts