Script that keeps guessing/entering codes in a game I play

Ask gaming related questions (AHK v1.1 and older)
PeptoPunk
Posts: 3
Joined: 18 Oct 2020, 16:31

Script that keeps guessing/entering codes in a game I play

Post by PeptoPunk » 18 Oct 2020, 16:36

I'm looking for/wondering how to make a script that can keep entering codes from a list of codes I generated in a game I play

User avatar
mikeyww
Posts: 26858
Joined: 09 Sep 2014, 18:38

Re: Script that keeps guessing/entering codes in a game I play

Post by mikeyww » 18 Oct 2020, 17:06

Code: Select all

code := ["a", "b", "c"], codeNum := 0

F3::
SoundBeep, codeNum < code.Count() ? 1500 : 900, 20
Send % code[++codeNum]
Return

PeptoPunk
Posts: 3
Joined: 18 Oct 2020, 16:31

Re: Script that keeps guessing/entering codes in a game I play

Post by PeptoPunk » 18 Oct 2020, 17:32

So how would I go about using this script? Sorry, I'm new to this

User avatar
mikeyww
Posts: 26858
Joined: 09 Sep 2014, 18:38

Re: Script that keeps guessing/entering codes in a game I play

Post by mikeyww » 18 Oct 2020, 17:35

As an example, the codes here are "a", "b", and "c". Every time you press F3, it inserts (sends) the next one in the list. You can run the script, open and activate Notepad, and then press F3 a few times, to see how it works.

PeptoPunk
Posts: 3
Joined: 18 Oct 2020, 16:31

Re: Script that keeps guessing/entering codes in a game I play

Post by PeptoPunk » 18 Oct 2020, 21:09

Okay, thank you!

Post Reply

Return to “Gaming Help (v1)”