Im trying to make a script to a game that will send a spacebar in 7 out of 8 game windows when turned on. Unfortunetly im not good enough to do it, and i can only do it in 1 window. I looked through forum and i did somethin like this:
Code: Select all
#NoEnv
SendMode Input
SetWorkingDir %A_ScriptDir%
#SingleInstance Force
Numpad1::
WinGet, hwnd1, ID, A
return
Numpad2::
WinGet, hwnd2, ID, A
return
F5::
loop
ControlSend, , {Space}, % "ahk_id " hwnd1
sleep, 2000
F6::
loop
ControlSend, , {Space}, % "ahk_id " hwnd2
sleep, 2000
Only 1 character out of 2 (for now) is looping space when i turn it on. How can i make 7 characters do it?
If it helps it is to Turn based RPG game where when you press space you skip turn, and passing through 8 separate windows is just annying.
Ty for all help . Have a good day!