Script help needed.

Ask gaming related questions (AHK v1.1 and older)
overtyped
Posts: 4
Joined: 02 Dec 2019, 07:06

Script help needed.

05 Feb 2020, 05:12

How do i get this script to work on a window in the background and only that window? I have a game open in the background and I'm trying to prevent it from logging out without me having to check on it periodically.



1::

Loop,

{

Send, {n down}
sleep, 100
Send, {n up}
sleep, 220000

}
Last edited by overtyped on 05 Feb 2020, 05:53, edited 1 time in total.
overtyped
Posts: 4
Joined: 02 Dec 2019, 07:06

Re: Script help needed.

05 Feb 2020, 20:42

bamp
User avatar
Yakshongas
Posts: 590
Joined: 21 Jan 2020, 08:41

Re: Script help needed.

06 Feb 2020, 12:16

use the

Code: Select all

if Winactive
like this

Code: Select all

1::
if WinActive, (windown name)
{
	Loop,

	{

	Send, {n down}
	sleep, 100
	Send, {n up}
	sleep, 220000

	}
}
Please mark your topics as solved if you don't need any further help. ✅

Need a little more help? Discord : Yakshongas#9893 🕹
overtyped
Posts: 4
Joined: 02 Dec 2019, 07:06

Re: Script help needed.

12 Feb 2020, 01:03

Yakshongas wrote:
06 Feb 2020, 12:16
use the

Code: Select all

if Winactive
like this

Code: Select all

1::
if WinActive, (windown name)
{
	Loop,

	{

	Send, {n down}
	sleep, 100
	Send, {n up}
	sleep, 220000

	}
}
Thanks for your help. Sadly for some reason this breaks the script and no longer works.

Return to “Gaming Help (v1)”

Who is online

Users browsing this forum: No registered users and 101 guests