Auch wenn ich die Opt fürs Mausklicken erhöhe, wird das identkit immer sofort ins erste Fach verschoben :(
Falsch!Quote:
zum fenstermodus...es sollte passen wenn du im autoitwindow info tool auf "window" in den optionen stellst. dann wird der balken vom fesnter meines wissens nach gleich abgezogen.
Opt("WinTitleMatchMode", 3)
Opt("MouseCoordMode", 2)
while 1
$pos = MouseGetPos()
tooltip("Mouse x,y: "& $pos[0] & "," & $pos[1], 0, 0)
Sleep(50)
wend
Func _MakeLong($LoWord, $HiWord)
Return BitOR($HiWord * 0x10000, BitAND($LoWord, 0xFFFF))
EndFunc ;==>_MakeLong
Func _MouseClick($hWnd, $button, $x, $y, $times = 1, $delay = 15) ; Use the relative coords to the client area of the active window
If $hWnd = 0 Then
SetError(-1)
Return
EndIf
Local $ix
Local $lParam = _MakeLong($x, $y)
Local $user32 = DllOpen("user32.dll")
$button = StringLower($button)
If $button = "left" Then
For $ix = 1 To $times
DllCall($user32, "int", "PostMessage", "hwnd", $hWnd, "int", 0x200, "int", 0, "long", $lParam) ; Move
DllCall($user32, "int", "PostMessage", "hwnd", $hWnd, "int", 0x201, "int", 1, "long", $lParam) ; Down
DllCall($user32, "int", "PostMessage", "hwnd", $hWnd, "int", 0x202, "int", 0, "long", $lParam) ; Up
If $ix < $times Then Sleep($delay)
Next
ElseIf $button = "right" Then
For $ix = 1 To $times
DllCall($user32, "int", "PostMessage", "hwnd", $hWnd, "int", 0x200, "int", 0, "long", $lParam) ; Move
DllCall($user32, "int", "PostMessage", "hwnd", $hWnd, "int", 0x204, "int", 2, "long", $lParam) ; Down
DllCall($user32, "int", "PostMessage", "hwnd", $hWnd, "int", 0x205, "int", 0, "long", $lParam) ; Up
If $ix < $times Then Sleep($delay)
Next
Else
SetError(-2)
If $user32 <> -1 Then DllClose($user32)
Return
EndIf
If $user32 <> -1 Then DllClose($user32)
EndFunc ;==>_MouseClick
Opt("MouseClickDelay", 1000)
func _ident()
$hwnd0 = WinGetHandle("Guild Wars")
ControlSend($hwnd0, "", "", "{.}")
Sleep(500)
$ident_x = 40
$ident_y = 318
$x = 41
$y = 78
For $iy = $y To $y + 140 Step 45
For $ix = $x To $x + 165 Step 40
ControlClick($hwnd0, "", "", "left", 2, $ident_x, $ident_y)
Sleep(3000)
_MouseClick($hwnd0, "left", $ix, $iy, 1, 80)
Next
Next
EndFunc ;==>ident
_ident()