Need Help GrandFantasia bot autoit

01/24/2010 13:27 clied#1
ok i read some tutorial about auto it and i could say i got the basic idea so far...

so im trying to make a bot in grandfantasia that:
1.select target (Tab)
2.attack(1 (attack action on action bar number 1))
3.repeat.

ok i think i got the tab part or the select target here

Code:
#include <GUIConstantsEx.au3>

GUISetState(@SW_SHOW)

GUICreate("Grand Fantsia Bot", 335, 100)

GUICtrlCreateLabel("On going bot...", 8, 10)

$startbutton = GUICtrlCreateButton("Start", 190, 8, 60)

GUISetState(@SW_SHOW)
WinActivate ("GrandFantasia")
WinWaitActive("GrandFantasia");

While 1
	$msg = GUIGetMsg()
	
	Select
		
		Case $msg = $startbutton
			while 1=1
				$i = 0
				while $i < 30
					Send ("{TAB}")
					Sleep (500)
					$i = $i + 1
				WEnd
			WEnd
			
		Case $msg = $GUI_EVENT_CLOSE
			GUIDelete()
			ExitLoop
			
	EndSelect
		
WEnd
im not sure yet if thats right but i tested it and it keeps on tabbing which its suppose to do now the prob is i cant figure out how to do the attack code and repeat, i just keep on getting error.. could someone enlighten me with some knowledge.

after this ill try to make the potion part(i just started using autoit sorry for noobish help for code):handsdown: