yuljk Posted July 21 Posted July 21 Hi guys - I have a PC game imported from GOG (Silent Hill 2 (2024) however, when existing the game BigBox is not in focus and hence I can't navigate atall - only fix is to plug in a keyboard and kill the leftover autohotkey process. I've tried using the following script after compiling and addiing as an additional app to run after the game closes from another user, but it doesn't work. Sleep, 5000 WinGet, active_id, ID, A WinWaitClose, ahk_id %active_id% Sleep, 3000 Send {Esc} Sleep, 500 if WinExist("LaunchBox") { WinActivate } if WinExist("LaunchBox BigBox") { WinActivate } ExitApp Any ideas on how I can improve this script or replace altogether? I'm running the latest version of Launchbox I should note, this is the only Windows game that has this issue in BigBox. Many thanks Quote
JoeViking245 Posted July 21 Posted July 21 29 minutes ago, yuljk said: I've tried using the following script after compiling and addiing as an additional app to run after the game closes from another user, but it doesn't work. Try setting it to run Before Main Application. Quote
yuljk Posted July 22 Author Posted July 22 Tried that - same issue unfortunately. I suspect the script isn't force closing the autohotkey process correctly. Quote
JoeViking245 Posted July 22 Posted July 22 14 minutes ago, yuljk said: Tried that - same issue unfortunately. I suspect the script isn't force closing the autohotkey process correctly. You may need more than 5 seconds for the game to initially load. Maybe try increasing the Sleep, 5000 to say, Sleep, 10000 (10 seconds). Load the game and wait at least 10 seconds before trying to close it. (Normally you'd "wait" a lot longer because you're actually "playing" it.) Also, you probably need to set a SetTitleMatchMode. But instead, just change the 2 if WinExist lines (respectively). if WinExist("ahk_exe LaunchBox.exe") if WinExist("ahk_exe BigBox.exe") Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.