Hi everyone,
I thought I would share my solution to use one PC to start a game on two (or more) PC's simultaneously - the use case for this is where one master cabinet "PLAYER 1" selects the game and starts that game on 2 PC's (in my case - my twin racing cabs).
• Eliminates the need to use a frontend on each cab
• Eliminates the need for the same game to be manually started on each cab at the same time
• Stops the initial "network sync" errors with some games if they are not both started at the same time
• Eliminates confusion for players
I am using the following to achieve this:
• LaunchBox (BigBox)
• AHK - AutoHotKey
• EXE Slideshow - this was used to make an animated "<<< Select Game on P1" screen for the PLAYER 2 cab
How it works:
• There is an AHK script that runs in the background on the PLAYER 2 cab looking for a "game" script in the folder C:\AHK to run. When no game is selected from PLAYER 1 the script keeps looping.
• While PLAYER 2 cab is waiting for a game selection from PLAYER 1 cab, an animated EXE slideshow is running on PLAYER 2 cab
• When PLAYER 1 selects a game, a "game" script is copied to folder C:\AHK on the PLAYER 2 cab
• The looping script on PLAYER 2 cab finds that a "game" script is in folder C:\AHK. It starts the game on PLAYER 2 cab, deletes the script from C:\AHK so the looping script can continue looking for game changes from PLAYER 1 cab
An extra:
• When the ESCAPE key/exit button is pressed on the PLAYER 1 cab it will send a script to the PLAYER 2 cab to exit the current playing game and open the EXE Slideshow on the PLAYER 2 cab and wait for a game selection from the PLAYER 1 cab
AN EXAMPLE: DAYTONA USA SELECTED ON PLAYER 1 CAB
#SingleInstance force
;---- COPY DAYTONA USA GAME.AHK TO PLAYER 2 CAB ----;
;---- NOTE= Y:\AHK IS THE NETWORKED DRIVE ON PLAYER 2 CAB (C:\AHK) ----;
FileCopy, C:\AHK\FilesToCopyToP2\Daytona USA\GAME.ahk, Y:\AHK
;---- START DAYTONA USA ON PLAYER 1 CAB ----;
Run, C:\AHK\Links\2P\Daytona USA.lnk, , Max
;---- WHEN ESC IS PRESSED ON PLAYER 1, CLOSE ALL GAMES ON PLAYER 1 AND SEND A CLOSE ALL GAMES SCRIPT TO PLAYER 2 ----;
ESC::
FileCopy, C:\AHK\Escape\GAME.ahk, Y:\AHK
Send !F4::
Process, Close, TeknoParrotUi.exe
Process, Close, sdaemon.exe
Process, Close, supermodel.exe
Process, Close, Daytona.exe
Process, Close, emulator_multicpu.EXE
Process, Close, parrotloader.exe
Process, Close, OpenParrotLoader64.exe
Process, Close, ParrotLoader64.exe
Process, Close, BudgieLoader.exe
Process, Close, Wmn5r.exe
Process, Close, Rally.exe
Process, Close, MK_AGP3_FINAL.exe
ExitAPP
return
PLAYER 2 - LOOKING FOR GAME LOOP SCRIPT:
;---- LOOK FOR GAME SCRIPT TO EXECUTE GAME ----;
IfExist, C:\AHK\GAME.ahk
Run GAME.ahk
Loop
Sleep, 2000
Reload
AN EXAMPLE: DAYTONA USA GAME SCRIPT THAT IS SENT TO PLAYER 2 CAB WHEN A GAME IS SELECTED ON PLAYER 1
#SingleInstance force
;---- CLOSE ALL POTENTIAL RUNNING GAMES ----;
Process, Close, TeknoParrotUi.exe
Process, Close, sdaemon.exe
Process, Close, supermodel.exe
Process, Close, Daytona.exe
Process, Close, emulator_multicpu.EXE
Process, Close, parrotloader.exe
Process, Close, OpenParrotLoader64.exe
Process, Close, ParrotLoader64.exe
Process, Close, BudgieLoader.exe
Process, Close, Wmn5r.exe
Process, Close, Rally.exe
Process, Close, MK_AGP3_FINAL.exe
;---- START DAYTONA USA ON PLAYER 2 CAB----;
Run, C:\AHK\Links\2P\Daytona USA.lnk, , Max
;---- DELETE GAME SCRIPT FROM LOOP SEARCH FOLDER ----;
FileDelete, C:\AHK\GAME.ahk
;---- IF ESC IS DETECTED CLOSE ALL POTENTIAL RUNNING GAMES ----;
ESC::
Process, Close, TeknoParrotUi.exe
Process, Close, sdaemon.exe
Process, Close, supermodel.exe
Process, Close, Daytona.exe
Process, Close, emulator_multicpu.EXE
Process, Close, parrotloader.exe
Process, Close, OpenParrotLoader64.exe
Process, Close, ParrotLoader64.exe
Process, Close, BudgieLoader.exe
Process, Close, Wmn5r.exe
Process, Close, Rally.exe
Process, Close, MK_AGP3_FINAL.exe
;---- CHECK IF EXE SLIDESHOW IS RUNNING ----;
Process, Exist, Player 2 - Waiting Screen 0.4.exe
If Not ErrorLevel ; errorlevel will = 0 if process doesn't exist
Run, C:\AHK\Player 2 - Waiting Screen 0.4.exe, , Max
ExitAPP
return
This is a pretty easy way to sync the execution of a game on multiple PC's - there's probably better ways, but hope this helps.
One draw back, is that you need to create a few scripts for every game you want to run on your cabs, this includes when you add new games.
Because this process is only required for my racing cabs and it only has a select few games, its easy to manage and isn't an issue for me.
If anyone would like further explanation please let me know.