Leo87 Posted December 9, 2009 Share Posted December 9, 2009 Hi, I'm new in using AutoIt and was working to make a simple bot for a game. I have some part of the script here.. Do ControlSend($win ,"" ,"" ,"2") ;send key 2 for the 2nd Skill Sleep(1000) ;stop for 1 sec ControlSend($win ,"" ,"" ,"1") ;send key 1 for the 1st Skill Sleep(1000) ;stop for 1 sec If PixelGetColor(102,146, $handle) <> 0xFF8242 Then ;Look if HP is less than specified (Only Instant HP should be used) ControlSend($win ,"" ,"" ,"4") ;Press 9 for + instant HP EndIf If PixelGetColor(93,159, $handle) <> 0x187DFF Then;Look if MP less than specified (Only Instant MP should be used) ControlSend($win ,"" ,"" ,"0") ;Press 0 for + instant MP Sleep(500) EndIf Until PixelGetColor(466,124, $handle) <> 0x426D8C ;Keep repeating until the selected monster died As my control are running in background, i have one big problem here; I could not fully run this bot on background. This means I have to make some part of the game open so that this script would work. So i figure it out, since all the key and mouse click is running on background, there left the PixelGetColor command that does not do so. So I would like to ask, Could I run the PixelGetColor in background? If can hope you can teach me. If Cannot, how do i solve this function? FYI, the PixelGetColor is used to check the HP and MP of the game. Hope someone can help me with this. Really Thanks.. Leo Link to comment Share on other sites More sharing options...
d0n Posted December 10, 2009 Share Posted December 10, 2009 the game needs to be visible on the screen, and i don't think there is anyway around it. but if someone knows a way, i'd like to know as well Link to comment Share on other sites More sharing options...
skyboy Posted December 10, 2009 Share Posted December 10, 2009 maybe someone else can provide a hook, but here's a proxy dll: http://www.mikoweb.eu/index.php?node=28 both the dll and C++ source Link to comment Share on other sites More sharing options...
Leo87 Posted December 11, 2009 Author Share Posted December 11, 2009 Hope someone could help..Bump Link to comment Share on other sites More sharing options...
eub08 Posted May 23, 2011 Share Posted May 23, 2011 (edited) - read sticky on the top of the forum before posting - removed content as its Game bot related. Edited May 23, 2011 by Jos Jos Link to comment Share on other sites More sharing options...
Recommended Posts