AHK 後台自動開始
想請教一下前輩們,後台自動開始怎寫,用ControlClick寫只有點擊功能,鼠標不會移動到指定的座標。本帖最後由 honey 於 2020-7-15 21:40 編輯
我也是用在學習中, 但我用這樣寫是可行的!
可以正常的移動滑鼠並點中視窗X鍵,
;創世模式下啟動三王者 1024*768
F1_N22:
IfWinExist,ahk_exe cstrike-online.exe
WinActivate
else
exitapp
SendInput {RButton Down}
Sleep 1000
SendInput {RButton up}
SendInput {LButton Down}
Sleep 100
;第二發
SendInput {E Down}
SendInput {RButton Down}
Sleep 800
SendInput {RButton Up}
SendInput {E Up}
Sleep 350
;第三發
SendInput {E Down}
SendInput {RButton Down}
Sleep 800
SendInput {E Up}
SendInput {RButton Up}
Sleep 200
SendInput {W Down}
Sleep 150
SendInput {Control Down}
SendInput {Space Down}
SendInput {Space Up}
SendInput {H}
Sleep 25
SendInput {Space}
Sleep 25
SendInput {Click 1001, 13 Down}
MouseMove 515, 407
Sleep 3000 ;卡窗秒數
SendInput {Click 515, 407 up}
Sleep 25
SendInput {H}
Sleep 25
SendInput {W Up}
SendInput {Control Up}
Return
頁:
[1]