AutoIT Problem

05/05/2009 17:44 Xereon#1
Edit: Problem hat sich gelöst


Also folgendes:
Ich will ein Teeworlds Emote Bot scripten(ein bot der die ganze zeitEemotes spamt) und ihn später eventuell auch ausbauen(instant messages auf shortkey usw.).
Das Grundscript an sich ist fertig und läuft eigentlich auch fehlerfrei.
Doch wenn ich jetz 1mal den Bot gestartet habe und wieder beendet reagiert die Mainwhile für das GUI auf kein Ereigniss mehr(man kann also nicht nocheinmal starten, kein delay ändern oder sont etwas).

Hab schon alles probiert und hoffe jetz das ihr mir helfen könnt:

Code:
Func Mainscript()
$msg = GUIGetMsg()	
	Select
		Case $msg = $GUI_EVENT_CLOSE
				ExitLoop
		Case $msg = $delaysetgui 
				$delay = GUICtrlRead($delaygui)
				GUICtrlDelete ($delayinfo)
				$delayinfo = GUICtrlCreateLabel ("Delay: " & $delay & " ms",260,15)
		Case $msg = $startGUI
				If $delay > 0 Then
				GUICtrlSetState ($stopGUI,$GUI_ENABLE)
				GUICtrlSetState ($startGUI,$GUI_DISABLE)
						For $i = 3 To 10 Step 1							
							$msg2 = GUIGetMsg()
							If $msg2 = $stopGUI Then
								GUICtrlSetState ($startGUI,$GUI_ENABLE)
								GUICtrlSetState ($stopGUI,$GUI_DISABLE)	
								$i = 10
							EndIf
							If $i = 10 Then
								$i = 3
							EndIf
							Select
							Case $i = 3	
							Send ("{F3}")
							Sleep($delay)
							Case $i = 4	
							Send ("{F4}")
							Sleep($delay)
							Case $i = 5
							Send ("{F5}")
							Sleep($delay)
							Case $i = 6	
							Send ("{F6}")
							Sleep($delay)
							Case $i = 7	
							Send ("{F7}")
							Sleep($delay)
							Case $i = 8	
							Send ("{F8}")
							Sleep($delay)
							Case $i = 9	
							Send ("{F9}")
							Sleep($delay)
							EndSelect
						Next
				Else
					MsgBox (-1,"Delay Error","Please enter a delay")						
				EndIf
		EndSelect
EndFunc
Sorry wenn keine Comments drin sind, aber so bin ich nunmal xD
05/15/2009 14:45 Pblx#2
post kompletten code ma
07/06/2009 07:33 jxsl13#3
würd ich auch ma sagen , weil man ja nicht sehen kann wohin welche variablen bzw. wohin welche funktionen hinführen .

erst danken dann tun...............

und meistens zeigt dir scite , wo der fehler liegt.......:rtfm::rtfm::rtfm:
04/05/2011 18:18 ^^^_#4
kannste den auch für mac coden?:O ich habe mac aber krieg kein spinbot...nix weils des für mac net gibt -.-
mfg
04/09/2011 21:44 Adroxxx#5
[Only registered and activated users can see links. Click Here To Register...]