Hey guys,
I'm a new user of this program called AutoHotKey. I got a gaming related question about how to use the program.
I am playing a game called Dofus. Its a fun game that I play when I get home after work or when I am from school. I got 4 accounts in total. I log all those accounts when I play to do quests and gain 4x the loot and money. However, I am getting sick of this alt+tab shortcuts to switch from my account to walk to the next map (mouse clicking system. you move with your mouse). Is there any code or something that will make my other 3/4 characters move when I am clicking on 1/4? So like when I am moving to the next map that I don't need to use alt+tab anymore and that the other 3 accounts move automatically?
I hope you guys can help me out of this ''problem''
Autohotkey Games Multiaccounting Help nedded with script!
-
- Posts: 7
- Joined: 11 Jun 2018, 07:40
Re: Autohotkey Games Multiaccounting Help nedded with script!
Search for MultiBoxing on this forum its been done many times before.
Re: Autohotkey Games Multiaccounting Help nedded with script!
If you don't have luck with multiboxing, I hope this helps, tested it in notepads because I don't play that game. Run the game windows in windowed if you can if you have trouble with getting the pid or sending input.
Code: Select all
if not (A_IsAdmin)
{
{
if A_IsCompiled
Run *RunAs "%A_ScriptFullPath%" /restart
else
Run *RunAs "%A_AhkPath%" /restart "%A_ScriptFullPath%"
}
ExitApp
}
#SingleInstance force
#Usehook
SetTitleMatchmode, 2
Suspend
lol = 0
Msgbox, ,MultiWindowInput, 'w','a','s', and 'd' are the keys being monitered. Right control is the activate and deactivate button. (Currently deactivated)
Msgbox, ,MultiWindowInput, Press middle mouse button to get the pid of the active window.
Inputbox, Winpid1, What is the pid of the first window?
Inputbox, Winpid2, What is the pid of the second window?
Inputbox, Winpid3, What is the pid of the third window?
$MButton::
Suspend
WinGetActiveTitle, Title
sleep, 100
WinGet, WindowPid, PID, %Title%
sleep, 100
MsgBox, ,MultiWindowInput, The pid of this window is %WindowPid%
Suspend
return
wd
~$RControl::
Suspend
lol=1
Return
$w::
Controlsend, , {w down}, ahk_pid %Winpid1%
Controlsend, , {w down}, ahk_pid %Winpid2%
if errorlevel
sleep, 1
Controlsend, , {w down}, ahk_pid %Winpid3%
if errorlevel
sleep, 1
Sendinput, {w down}
KeyWait, w, D
Sendinput, {w up}
Controlsend, , {w up}, ahk_pid %Winpid1%
Controlsend, , {w up}, ahk_pid %Winpid2%
if errorlevel
sleep, 1
Controlsend, , {w up}, ahk_pid %Winpid3%
if errorlevel
sleep, 1
Return
$d::
Controlsend, , {d down}, ahk_pid %Winpid1%
Controlsend, , {d down}, ahk_pid %Winpid2%
if errorlevel
sleep, 1
Controlsend, , {d down}, ahk_pid %Winpid3%
if errorlevel
sleep, 1
Sendinput, {d down}
KeyWait, d, D
Sendinput, {d up}
Controlsend, , {d up}, ahk_pid %Winpid1%
Controlsend, , {d up}, ahk_pid %Winpid2%
if errorlevel
sleep, 1
Controlsend, , {d up}, ahk_pid %Winpid3%
if errorlevel
sleep, 1
Return
$s::
Controlsend, , {s down}, ahk_pid %Winpid1%
Controlsend, , {s down}, ahk_pid %Winpid2%
if errorlevel
sleep, 1
Controlsend, , {s down}, ahk_pid %Winpid3%
if errorlevel
sleep, 1
Sendinput, {s down}
KeyWait, s, D
Sendinput, {s up}
Controlsend, , {s up}, ahk_pid %Winpid1%
Controlsend, , {s up}, ahk_pid %Winpid2%
if errorlevel
sleep, 1
Controlsend, , {s up}, ahk_pid %Winpid3%
if errorlevel
sleep, 1
Return
$a::
Controlsend, , {a down}, ahk_pid %Winpid1%
Controlsend, , {a down}, ahk_pid %Winpid2%
if errorlevel
sleep, 1
Controlsend, , {a down}, ahk_pid %Winpid3%
if errorlevel
sleep, 1
Sendinput, {a down}
KeyWait, a, D
Sendinput, {a up}
Controlsend, , {s up}, ahk_pid %Winpid1%
Controlsend, , {s up}, ahk_pid %Winpid2%
if errorlevel
sleep, 1
Controlsend, , {s up}, ahk_pid %Winpid3%
if errorlevel
sleep, 1
Return
-
- Posts: 7
- Joined: 11 Jun 2018, 07:40
Re: Autohotkey Games Multiaccounting Help nedded with script!
It keep saying error at line 32.Shade4Real wrote:If you don't have luck with multiboxing, I hope this helps, tested it in notepads because I don't play that game. Run the game windows in windowed if you can if you have trouble with getting the pid or sending input.Code: Select all
if not (A_IsAdmin) { { if A_IsCompiled Run *RunAs "%A_ScriptFullPath%" /restart else Run *RunAs "%A_AhkPath%" /restart "%A_ScriptFullPath%" } ExitApp } #SingleInstance force #Usehook SetTitleMatchmode, 2 Suspend lol = 0 Msgbox, ,MultiWindowInput, 'w','a','s', and 'd' are the keys being monitered. Right control is the activate and deactivate button. (Currently deactivated) Msgbox, ,MultiWindowInput, Press middle mouse button to get the pid of the active window. Inputbox, Winpid1, What is the pid of the first window? Inputbox, Winpid2, What is the pid of the second window? Inputbox, Winpid3, What is the pid of the third window? $MButton:: Suspend WinGetActiveTitle, Title sleep, 100 WinGet, WindowPid, PID, %Title% sleep, 100 MsgBox, ,MultiWindowInput, The pid of this window is %WindowPid% Suspend return wd ~$RControl:: Suspend lol=1 Return $w:: Controlsend, , {w down}, ahk_pid %Winpid1% Controlsend, , {w down}, ahk_pid %Winpid2% if errorlevel sleep, 1 Controlsend, , {w down}, ahk_pid %Winpid3% if errorlevel sleep, 1 Sendinput, {w down} KeyWait, w, D Sendinput, {w up} Controlsend, , {w up}, ahk_pid %Winpid1% Controlsend, , {w up}, ahk_pid %Winpid2% if errorlevel sleep, 1 Controlsend, , {w up}, ahk_pid %Winpid3% if errorlevel sleep, 1 Return $d:: Controlsend, , {d down}, ahk_pid %Winpid1% Controlsend, , {d down}, ahk_pid %Winpid2% if errorlevel sleep, 1 Controlsend, , {d down}, ahk_pid %Winpid3% if errorlevel sleep, 1 Sendinput, {d down} KeyWait, d, D Sendinput, {d up} Controlsend, , {d up}, ahk_pid %Winpid1% Controlsend, , {d up}, ahk_pid %Winpid2% if errorlevel sleep, 1 Controlsend, , {d up}, ahk_pid %Winpid3% if errorlevel sleep, 1 Return $s:: Controlsend, , {s down}, ahk_pid %Winpid1% Controlsend, , {s down}, ahk_pid %Winpid2% if errorlevel sleep, 1 Controlsend, , {s down}, ahk_pid %Winpid3% if errorlevel sleep, 1 Sendinput, {s down} KeyWait, s, D Sendinput, {s up} Controlsend, , {s up}, ahk_pid %Winpid1% Controlsend, , {s up}, ahk_pid %Winpid2% if errorlevel sleep, 1 Controlsend, , {s up}, ahk_pid %Winpid3% if errorlevel sleep, 1 Return $a:: Controlsend, , {a down}, ahk_pid %Winpid1% Controlsend, , {a down}, ahk_pid %Winpid2% if errorlevel sleep, 1 Controlsend, , {a down}, ahk_pid %Winpid3% if errorlevel sleep, 1 Sendinput, {a down} KeyWait, a, D Sendinput, {a up} Controlsend, , {s up}, ahk_pid %Winpid1% Controlsend, , {s up}, ahk_pid %Winpid2% if errorlevel sleep, 1 Controlsend, , {s up}, ahk_pid %Winpid3% if errorlevel sleep, 1 Return
Line text wd.
Error: this line does not containt a recognized action.
The program will exit.
I hit the file with right click and then run script, but I get this message everytime. I don't know what to do.. do you know what that means with the wd thingy?
-
- Posts: 7
- Joined: 11 Jun 2018, 07:40
Re: Autohotkey Games Multiaccounting Help nedded with script!
I removed the wd and now it gave me a option about to insert a pid or something. I pressed 1 for window 1, 2 for window 2 and 3 for window 3. If I press 1 and try to walk, nothing happends. The same is happening right now for pid 2 and pid 3.. Am I doing something wrong?
-
- Posts: 7
- Joined: 11 Jun 2018, 07:40
Re: Autohotkey Games Multiaccounting Help nedded with script!
Could you maybe tag me or make a ss ofnit and show it to me?Xtra wrote:Search for MultiBoxing on this forum its been done many times before.