• You've discovered RedGuides, an EverQuest multi-boxing and scripting community 🧙‍♀️⚙️. We want you to play several EQ characters at once, come join us and say hello! 👋

  • A TLP without truebox has thawed (Very Vanilla ready)
    Frostreaver

Simple AHK - Game loader (requires you to have mq2autologin configured)

redraj

New member
Joined
Feb 1, 2015
RedCents
571¢
Hi, this is a very basic autohotkey script that I use to load up MQ2, EQBCS, and my 6 accounts. It creates a standard looking AHK icon in your taskbar, right click it & select start everquest.

It copies over my specified eqclient.ini files allowing each character to open up at the same place with the proper window size everytime.

I hope this helps some of you, and maybe someone can make it better (I barely know what I'm doing)

You'll need to change the directories to match your locations & eqclient.ini copies (nothing a ctrl+h can't change in a minute for you). There is a 10 second delay between each start, you can try lowering it or raising it if your MQ2 crashes your EQ on load (I use 40sec delays)

Rich (BB code):
#Persistent
;;;;;Tray Menu Setup
Menu:
Menu, Tray, Tip, Everquest Launcher
Menu, Tray, NoStandard
Menu, Tray, Add, Start Everquest, EQ-1
Menu, Tray, Add
Menu, Tray, Add, Exit Script, ExitSub
return

MQLaunched = 0

EQ-1:
If A_ThisMenuItem = Start Everquest
{

;Start MQ2 and EQBCS
IfExist C:\MacroQuest2\MacroQuest2.exe
{
	Process, Exist, MacroQuest2.exe
	If (!ErrorLevel= 0)
	{
		MQLaunched = 1
	} else {
		run, C:\MacroQuest2\MacroQuest2.exe, C:\MacroQuest2
		run, C:\MacroQuest2\MQ2EQBCS.exe, C:\MacroQuest2
		MQLaunched = 1
	}

} else {
	MsgBox, MacroQuest not found at C:\MacroQuest2\MacroQuest2.exe
	Goto, ExitSub
}
	
sleep 1000 ;1 sec pause

;Start Everquest from directory
	If MQLaunched >=1
	{
		FileCopy, C:\MacroQuest2\eqclient\eqclient1.ini, C:\EverQuest\eqclient.ini, 1
		   run, C:\EverQuest\eqgame.exe patchme /login, C:\EverQuest
		sleep 10000 ;10 sec pause

		FileCopy, C:\MacroQuest2\eqclient\eqclient2.ini, C:\EverQuest\eqclient.ini, 1
		run, C:\EverQuest\eqgame.exe patchme /login, C:\EverQuest
		sleep 10000 ;10 sec pause

		FileCopy, C:\MacroQuest2\eqclient\eqclient3.ini, C:\EverQuest\eqclient.ini, 1
		run, C:\EverQuest\eqgame.exe patchme /login, C:\EverQuest
		sleep 10000 ;10 sec pause

		FileCopy, C:\MacroQuest2\eqclient\eqclient4.ini, C:\EverQuest\eqclient.ini, 1
		run, C:\EverQuest\eqgame.exe patchme /login, C:\EverQuest
		sleep 10000 ;10 sec pause

		FileCopy, C:\MacroQuest2\eqclient\eqclient5.ini, C:\EverQuest\eqclient.ini, 1
		run, C:\EverQuest\eqgame.exe patchme /login, C:\EverQuest
		sleep 10000 ;10 sec pause

		FileCopy, C:\MacroQuest2\eqclient\eqclient6.ini, C:\EverQuest\eqclient.ini, 1
		run, C:\EverQuest\eqgame.exe patchme /login, C:\EverQuest
		return

	} else {
		MQLaunched = 0
		Msgbox, Macroquest2 not running
	}
} else {
	Msgbox, Menu broke
}

ExitSub:
ExitApp
 
awesome gona give this a try. redcented


err stoopid question what do i save file as? lol


foegt above noob question , sorted it thanks
 
This is not far off from what I run on my PC except I use standard batch file execution and leverage the WINEQ2 shortcuts and ping pauses/timer. Nice work, have used AHK in the past and have enjoyed it's functionality in games. Redcented for an awesome way of using AHK

Scotsbiker, save it as an .ahk file


----Update----

@echo off
Echo "Starting EQBC..."
start c:\MQ2\MQ2EQBCS.exe
ping 127.0.0.1 -n 5 > nul
Echo "Starting Macroquest2..."
start C:\MQ2\MacroQuest2.exe
ping 127.0.0.1 -n 5 > nul
Echo "Starting WinEQ2..."
cd "C:\Program Files (x86)\WinEQ2"
start WinEQ2.exe
ping 127.0.0.1 -n 5 > nul
Echo "Starting All EQ Windows"
ping 127.0.0.1 -n 5 > nul
cd "c:\Users\xxxxxx\Desktop\"
Echo "Launching xxxxxxxx..."
"EverQuest - xxxxxxxx.lnk"
ping 127.0.0.1 -n 20 > nul
Echo "Launching xxxxxxx..."
"EverQuest - xxxxxxx.lnk"
ping 127.0.0.1 -n 20 > nul
Echo "Launching xxxxxx..."
"EverQuest - xxxxxxx.lnk"
ping 127.0.0.1 -n 20 > nul
Echo "Launching xxxxxxx..."
"EverQuest - xxxxxxxx.lnk"
ping 127.0.0.1 -n 20 > nul

Echo " All Instances of EQ have been launched. Enjoy the game!!"
pause



----Update----

Also I leverage MQ2Autologin to log into each WINEQ2 instances opened so I run the script and come back after about a minute to everything logged in and ready to group up and begin rolling.
 
I've currently been working with getting AHK things setup on multiple machines using Google Remote Access to launch groups on different machines when I came across this gem of a post. I took the AHK layout above and modified it to my own use to use WinEQ teams on each computer. The character accounts are setup with desktop shortcuts from WinEQ for the launcher to use. This keeps WinEQ functionality and PlayNice in place accordingly. Each computer has this AHK macro setup for the team running on it as an .exe output named by team it launches. On my main main, I log onto each computer with the remote access and then launch. A few minutes later, that machine is up and running with it's full teams. Thanks to the guys above for their posts! I hope my small additional is useful to someone else as theirs was to me.

Rich (BB code):
#Persistent
;;;;;Tray Menu Setup
Menu:
Menu, Tray, Tip, Everquest Launcher
Menu, Tray, NoStandard
Menu, Tray, Add, Start Everquest, EQ-1
Menu, Tray, Add
Menu, Tray, Add, Exit Script, ExitSub
return

MQLaunched = 0

EQ-1:
If A_ThisMenuItem = Start Everquest
{

;Start MQ2, EQBCS, and WinEQ 2.0
IfExist E:\Game Tools\MacroQuest2 Redguides\MacroQuest2.exe
{
	Process, Exist, MacroQuest2.exe
	If (!ErrorLevel= 0)
	{
		MQLaunched = 1
	} else {
		;;;;;;Change the directory information for where you have installed MacroQuest2.exe 
		;;;;;;and WinEQ2.exe and working folders accordingly in the few lines. Below are examples
		;;;;;;using another drive other than the C: and our favority Redguides install folders!
		run, E:\Game Tools\MacroQuest2 Redguides\MacroQuest2.exe, E:\Game Tools\MacroQuest2 Redguides
		sleep 100 ; 1 sec pause
		run, E:\Game Tools\MacroQuest2 Redguides\MQ2EQBCS.exe, E:\Game Tools\MacroQuest2 Redguides
		sleep 100 ; 1 sec pause
		run, E:\Game Tools\WinEQ2\WinEQ2.exe, E:\Game Tools\WinEQ2
		MQLaunched = 1
	}

} else {
	MsgBox, MacroQuest not found at E:\Game Tools\MacroQuest2 Redguides\MacroQuest2.exe
	Goto, ExitSub
}
	
sleep 1000 ;1 sec pause

;Start Everquest from directory
	If MQLaunched >=1
	{
		;;;;;;;Replace the xxxxxxx sections with your users pathing for desktop and the XXXXXXXX 
		;;;;;;;with the WinEQ character link name. You can duplicate each run section to add or
		;;;;;;;remove more or less accounts you're logging into from the same computer.
		run, C:\Users\xxxxxx\Desktop\Everquest - XXXXXX.lnk
		sleep 10000 ;10 sec pause

		run, C:\Users\xxxxxx\Desktop\Everquest - XXXXXX.lnk
		sleep 10000 ;10 sec pause

		run, C:\Users\xxxxxx\Desktop\Everquest - XXXXXX.lnk
		sleep 10000 ;10 sec pause

		run, C:\Users\xxxxxx\Desktop\Everquest - XXXXXX.lnk
		sleep 10000 ;10 sec pause

	} else {
		MQLaunched = 0
		Msgbox, Macroquest2 not running
	}
} else {
	Msgbox, Menu broke
}

ExitSub:
ExitApp
 
Could this be done for ISboxer? Or should i move away from it?

Thanks

You can configure ISBoxer with delays between loading sessions built in. So make your teams, and configure that. Then you just configure the ini file for Autologin as per original positing. Then you can use the pieces of the AHK to make the hotkey to start things. First have it start MQ2, then ISBoxer, EQBCS server if you're hosting one, Hotkey that launches the configured team previously note, and you're in business.
 
I found that when loading up multiple characters, MQ2Autologin would be confused-- there would already be a name in the login box and MQ2login would not remove it. This would lead to all kinds of login mayhem. For background info: Windows 10 Pro, all updates, top notch computer, etc.

I traced the fix to the eqlsPlayerData.ini file in the Everquest folder. It holds the name of the last character logged in. So I copied that file into the MQ2 folder and removed from it the following two lines:

[PLAYER]
Username=XXXX


Then, in the "Gameloader.mac" file from this thread, I added the following line after the FileCopy of the eqclient.ini file:

FileCopy, C:\MQ2\eqlsPlayerData.ini, C:\Users\Public\Daybreak Game Company\Installed Games\EverQuest\eqlsPlayerData.ini, 1

That basically copies in a "blank" to the eqlsPlayerData.ini before each Everquest.exe launch and thereby lets MQ2Autologin work with a fresh/blank login. I also increased the sleep time between loading to 60 seconds, just to be safe (even though I have a top end computer). Extra sleep time is probably not needed, but...

This fixed the login mixup/mayhem for me.

Final program is here:
Rich (BB code):
#Persistent
;;;;;Tray Menu Setup
Menu:
Menu, Tray, Tip, Everquest Launcher
Menu, Tray, NoStandard
Menu, Tray, Add, Start Everquest, EQ-1
Menu, Tray, Add
Menu, Tray, Add, Exit Script, ExitSub
return

MQLaunched = 0

EQ-1:
If A_ThisMenuItem = Start Everquest
{

;Start MQ2 and EQBCS
IfExist C:\MQ2\MacroQuest2.exe
{
	Process, Exist, MacroQuest2.exe
	If (!ErrorLevel= 0)
	{
		MQLaunched = 1
	} else {
		run, C:\MQ2\MacroQuest2.exe, C:\MQ2
		run, C:\MQ2\MQ2EQBCS.exe, C:\MacroQuest2
		MQLaunched = 1
	}

} else {
	MsgBox, MacroQuest not found at C:\MQ2\MacroQuest2.exe
	Goto, ExitSub
}
	
sleep 1000 ;1 sec pause

;Start Everquest from directory
	If MQLaunched >=1
	{
		FileCopy, C:\MQ2\eqclient1.ini, C:\Users\Public\Daybreak Game Company\Installed Games\EverQuest\eqclient.ini, 1
		FileCopy, C:\MQ2\eqlsPlayerData.ini, C:\Users\Public\Daybreak Game Company\Installed Games\EverQuest\eqlsPlayerData.ini, 1
		   run, C:\Users\Public\Daybreak Game Company\Installed Games\EverQuest\eqgame.exe patchme /login, C:\Users\Public\Daybreak Game Company\Installed Games\EverQuest
		sleep 60000 ;10 sec pause

		FileCopy, C:\MQ2\eqclient2.ini, C:\Users\Public\Daybreak Game Company\Installed Games\EverQuest\eqclient.ini, 1
		FileCopy, C:\MQ2\eqlsPlayerData.ini, C:\Users\Public\Daybreak Game Company\Installed Games\EverQuest\eqlsPlayerData.ini, 1
		run, C:\Users\Public\Daybreak Game Company\Installed Games\EverQuest\eqgame.exe patchme /login, C:\Users\Public\Daybreak Game Company\Installed Games\EverQuest
		sleep 60000 ;10 sec pause

		FileCopy, C:\MQ2\eqclient3.ini, C:\Users\Public\Daybreak Game Company\Installed Games\EverQuest\eqclient.ini, 1
		FileCopy, C:\MQ2\eqlsPlayerData.ini, C:\Users\Public\Daybreak Game Company\Installed Games\EverQuest\eqlsPlayerData.ini, 1
		run, C:\Users\Public\Daybreak Game Company\Installed Games\EverQuest\eqgame.exe patchme /login,C:\Users\Public\Daybreak Game Company\Installed Games\EverQuest
		sleep 60000 ;10 sec pause

		FileCopy, C:\MQ2\eqclient4.ini, C:\Users\Public\Daybreak Game Company\Installed Games\EverQuest\eqclient.ini, 1
		FileCopy, C:\MQ2\eqlsPlayerData.ini, C:\Users\Public\Daybreak Game Company\Installed Games\EverQuest\eqlsPlayerData.ini, 1
		run, C:\Users\Public\Daybreak Game Company\Installed Games\EverQuest\eqgame.exe patchme /login, C:\Users\Public\Daybreak Game Company\Installed Games\EverQuest
		sleep 60000 ;10 sec pause

		return

	} else {
		MQLaunched = 0
		Msgbox, MQ2 not running
	}
} else {
	Msgbox, Menu broke
}

ExitSub:
ExitApp
 
Last edited:
Uhm, I'm adding mq2autologin to core, not removing it.
It will be a core supported plugin, I'll do my best to keep it backwards compatible.
 
I'm working on something similar with a powershell script.
I have custom window titles etc... as my Overseer project needs to support multiple groups on one pc. The original design was kill all eqgame.exe clients
once my shutdown event fired.

I'm now only killing the clients of characters that are in the group that triggered the shutdown.

The other option is to just make a 24 slot Innerspace character group :) I like Innerspace as it adds hotkeys to toggle window swaps.
 
Nice work Joojoo!


Just FYI though, MQ2Autologin is going to be deprecated next patch, and likely removed from the compile in a month or two. eqmule is building it into core MQ2, and it will be encrypted, so no more plaintext passwords on your HDD.

http://www.macroquest2.com/phpBB3/viewtopic.php?f=17&t=20027&p=171803&hilit=wineq#p171803

The only problem with no plain text passwords on my hard drive is that IF I need to manually login (patch day or something) I will never remember the password for the account! I'll have to check to see if there is a way to view the pwd for these situations.
 
This powershell script launches EQ with the window title "EQ-MyChar" and the value "MyAccount" will be in the login field.
I'm not messing with copying of any files... so last used values in eqclient.ini and eqlsPlayerData.ini is used. Curious to see how Innerspace virtualizes it's config files.
It doesn't appear to be overwriting any of the named files on launch, so if I can figure out the command line args for eqgame.exe I'll update this.

Rich (BB code):
Add-Type -TypeDefinition @"
using System;
using System.Runtime.InteropServices;

public static class Win32Api
{
    [DllImport("User32.dll", EntryPoint = "SetWindowText")]
    public static extern int SetWindowText(IntPtr hWnd, string text);
}
"@






function Launch-Everquest()
{
	param([string] $character, [string] $account)
	$path = "c:\Users\Public\Daybreak Game Company\Installed Games\EverQuest\"
	$arguments = "patchme /login:${account}"

	cd $path
	
	$process = Start-Process -FilePath $path"eqgame.exe" -ArgumentList $arguments -PassThru
	$process.WaitForInputIdle()
	[Win32Api]::SetWindowText($process.MainWindowHandle, "EQ-${character}")
}

Launch-Everquest -character "MyChar" - account "MyAccount"
 
For those that use WINEQ2, this requires that you setup a profile with your character names.
It was kind of tedious, but I did one profile for each character and I was able to get the EQPlayNice / Hotkey swapping that comes with WinEQ2.
It's not perfect, as WINEQ2 caps out at 8 keyboard shortcuts, so I just made sure I have Previous Window and Next Window keyboard to my Gkeys.

Rich (BB code):
function Launch-WinEQ()
{
	param([string] $character)
	$path = "C:\Program Files (x86)\WinEQ2\" 
	$arguments = "/plugin:WinEQ2-EQ.dll ${character}"
	
	cd $path
	Start-Process -FilePath $path"WinEQ2.exe" -ArgumentList $arguments
}

Launch-WinEQ -character "Char1"
Start-Sleep -s 1
Launch-WinEQ -character "Char2"
Start-Sleep -s 1
Launch-WinEQ -character "Char3"
 
Simple AHK - Game loader (requires you to have mq2autologin configured)

Users who are viewing this thread

Back
Top
Cart