Jump to content
LaunchBox Community Forums

Auto Hotkey Scripts


Lordmonkus

Recommended Posts

32 minutes ago, jacks897 said:

Hey, would it be possible to make it so that pressing the guide button 2 times quickly would trigger the script?

 

I figured this one out myself, here it is if it helps anyone else

vk07::

If (A_ThisHotkey == A_PriorHotkey && A_TimeSincePriorHotkey < 400)
{
if !WinExist("ahk_exe yBigBox.exe")
    Run C:\Users\Jack\LaunchBox\Core\BigBox.exe   
else
    WinActivate, ahk_exe BigBox.exe

Run %A_ScriptDir%\nircmd.exe setdefaultsounddevice "32W_LCD_TV" ;

send {esc}

WinClose, ahk_exe retroarch.exe

WinClose, ahk_exe Dolphin.exe

WinClose, ahk_exe pcsx2.exe

WinClose, ahk_exe pcsx2.exe

WinClose, ahk_exe PPSSPP

WinClose, ahk_exe kodi.exe

WinClose, ahk_exe citra-qt.exe

WinClose, ahk_exe Cemu.exe

Send {y}

}

 

 

  • Thanks 1
Link to comment
Share on other sites

5 hours ago, jacks897 said:

Does anyone know how to shrink a PCem hard drive .img file?

You can't. But you shouldn't be using .img hdds anyway. PCem (v17) lets you create variable size / dynamically-expanding vhds. You specify a size that you want to be seen in the VM - 16GB, 32GB, whatever you want - but the actual size that it occupies is only however much space is used by the files on the drive, and it dynamically expands as you add more, up to whatever the maximum size was that your specified on creation.

Link to comment
Share on other sites

Thanks, that sounds like a much better way of using the hdd's. Is there a way to convert an img hard drive to a vhd?

i downloaded a copy of a Windows 98 image on Archive.org that was already configured for pcem, that's why I have an img file :)
 

Link to comment
Share on other sites

I don't believe so, no.

You could always "reverse engineer" one of my game packages that use PCem, just uninstalling the game in the 98 environment and then putting whatever you wanted on. The newer ones are setup with variable vhds. The older ones are imgs, from before those were available.

https://www.zombs-lair.com/

It's pretty easy to just start from scratch though if you want to go that route. I'd recommend using 98SE + FIC VA-503+ or later mobo as this allows you to shut down the computer and then PCem automatically closes itself.

Link to comment
Share on other sites

Hey guys, I was wondering if any of you knew about an app that could possibly map a button on the keyboard or on a controller to a mouse to at a specific point on screen. This would be extremely help in Cemu games like Splatoon where in order to squid jump you need to use the mouse which is a hassle. Have a simple button to click it for you would be a phenomenal idea. Let me know in the comments if you guys have anything that can do this! ❤️

Link to comment
Share on other sites

1 hour ago, Krakatoa said:

If GetKeyState("Joy4")

You only need this if needing to use a button combination.  Try this (not tested)

1Joy4::
{
   SetKeyDelay, -1, 110
   Send {F1}{F2}
}
Return

I don't know if the 1st "1" is required to tell it to look for Controller #1.  But in past tests, I know it works.

This will send a keypress to {F1} and then to {F2}.  [vs. sending  {F1}  a_literal_comma  {F2} ]

Link to comment
Share on other sites

3 hours ago, JoeViking245 said:

You only need this if needing to use a button combination.  Try this (not tested)


1Joy4::
{
   SetKeyDelay, -1, 110
   Send {F1}{F2}
}
Return

I don't know if the 1st "1" is required to tell it to look for Controller #1.  But in past tests, I know it works.

This will send a keypress to {F1} and then to {F2}.  [vs. sending  {F1}  a_literal_comma  {F2} ]

thanks, for some reason, its still not working. Maybe there's a special way needed for the Dolphin emulator

Link to comment
Share on other sites

3 hours ago, Krakatoa said:

Maybe there's a special way needed for the Dolphin emulator

Not sure exactly what your wanting to do in Dolphin.   Load a save state? Do Frame Advance [fast forward]?...  If it's something like that, you can set those in Dolphin itself.  Go to Options, Hotkey Settings.   Make sure "Device" is set to XInput/Gamepad for it to register the controller.  Then go to the tab you need and click once in the box you want to set, then press the appropriate controller button.

Link to comment
Share on other sites

13 hours ago, JoeViking245 said:

Not sure exactly what your wanting to do in Dolphin.   Load a save state? Do Frame Advance [fast forward]?...  If it's something like that, you can set those in Dolphin itself.  Go to Options, Hotkey Settings.   Make sure "Device" is set to XInput/Gamepad for it to register the controller.  Then go to the tab you need and click once in the box you want to set, then press the appropriate controller button.

When Mario GP and GP2 launch and the Nintendo screen shows you need to press F1 or F2 to proceed, F1 is for GP1 and F2 is for GP2, my goal was to create an AHK script that would simulate a keyboard press, so I don't have to keep a keyboard in racing cab.

I think the script it correct, but for some reason its not working with Dolphin

Link to comment
Share on other sites

17 minutes ago, Krakatoa said:

Mario GP and GP2

It's F1 for both my GP1 and GP2.  I use a 'dedicated' version of Dolphin just for these 2 and set it up like so..

image.png.21b7e9a08a17fff8fababc3a31c701b0.png

Depending on your games' load time, you may need to adjust the sleep 4 seconds ("4000").  And if your GP2 is indeed F2, and pressing F1 doesn't 'hurt' it (and visa versa for GP1)... copy and paste the last 3 lines to below what's there and change "F1" to F2".  Then play and have loads of fun! :D

Link to comment
Share on other sites

1 minute ago, JoeViking245 said:

It's F1 for both my GP1 and GP2.  I use a 'dedicated' version of Dolphin just for these 2 and set it up like so..

image.png.21b7e9a08a17fff8fababc3a31c701b0.png

Depending on your games' load time, you may need to adjust the sleep 4 seconds ("4000").  And if your GP2 is indeed F2, and pressing F1 doesn't 'hurt' it (and visa versa for GP1)... copy and paste the last 3 lines to below what's there and change "F1" to F2".  Then play and have loads of fun! :D

You are awesome, thank you!!

BTW these games are awesome.

  • Game On 1
Link to comment
Share on other sites

  • 2 weeks later...

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...