Code:
HotKeySet ("{F1}", "gegenrot" )
HotKeySet ("{F2}", "gegenblau" )
HotKeySet ("{F10}", "stop" )
HotKeySet ("{Delete}", "quit" )
HotKeySet ("{F11}", "hilfe")
Func gegenrot ()
While 1
Sleep ( 1000 )
$coord = PixelSearch(0,0,1280,1024,0xFF060E,30,10)
sleep (100)
if not @error then
MouseClick("left",$coord[0],$coord[1],10)
sleep (100)
EndIf
WEnd
EndFunc
Func gegenblau ()
While 1
Sleep ( 1000 )
$coord = PixelSearch(0,0,1280,1024,0xE5F9D5,30,10)
if not @error then
MouseClick("left",$coord[0],$coord[1],10)
EndIf
WEnd
EndFunc
While 1
sleep ( 100)
WEnd
Func Hilfe ()
MsgBox(0,"Help", "F1 = Gegen Rot" & @CR & _
"F2 = Gegen Blau" & @CR & _
"F11 = Pause" & @CR & _
"P = PoLyToXiC beenden.")
EndFunc
Func stop ()
While 1
Sleep(100)
WEnd
EndFunc
Func quit ()
MsgBox (0, "PoLyToXiC", " " & @CR & _
"PoLyToXiC by Snipa." & @CR & _
" " & @CR & _
"DaRkNeSs-GaMiNg")
Exit
EndFunc
Line 24 (File "Pfad"
MouseClick("left",$coord[0],$coord[1],10)
MouseClick("left",coord^ERROR
Error: Subscript used with non-Array variable
____
Der Fehler passiert aber nur, wenn kein roter Pixel gefunden wird.
Kann mir jemand sagen, was ich flasch mache ?