BryceTheCoder Posted November 20, 2011 Share Posted November 20, 2011 Hey i know how to make a color ID such as: BankColor := 11066876; buuutt i dont know the code for making it say something like: "If the color is on the screen, move mouse on it then left-click the color." Quote Link to comment Share on other sites More sharing options...
sjesper Posted December 2, 2011 Share Posted December 2, 2011 (edited) U can use this method: [Code] if findColor(x, y, BankColor, 0, 0, w - 1, h - 1) then begin ClickWindMouse(x, y, 5, 5, True); end; [/Code] Or u can make it to a function, that makes it alot easier. [Code] function ClickColor(const c, x, y: Integer): integer; begin GetClientDimensions(w, h); if findColor(x, y, c, 0, 0, w - 1, h -1) then begin ClickWindMouse(x, y, 2, 2, True); end; end;[/Code] Now all you need to do is write: ClickColor((Color), (x), (y); and it will click it. An example: [Code] ClickColor(23583, 401, 102); [/code] Edited December 2, 2011 by sjesper Quote Link to comment Share on other sites More sharing options...