C_Wilson009 Posted April 17, 2015 Share Posted April 17, 2015 Hi there, Could someone help me with making a script for autohotkey? When I press the letter M and then 5 together, I want it to press escape. Its probably easy to some, but this is difficult for me. Link to comment Share on other sites More sharing options...
Metalzoic Posted April 26, 2015 Share Posted April 26, 2015 I just started messing with AHK an hour ago and I thought just putting the line M5::Escapewould do what you need, but Hyperlaunch says it is an error. Hopefully someone who knows it well can help? I'm trying to get AHK to enable Vjoy from the device manager and then disable it again when MKX closes. I'm not even sure if that is possible. Link to comment Share on other sites More sharing options...
Metalzoic Posted April 26, 2015 Share Posted April 26, 2015 Hey I just got it to work for you! Use this line M & 5::send, {Escape}Seems to work. No idea why it needs the "&" symbol, but it seems to need the "send," command when changing to a special key like Escape. Link to comment Share on other sites More sharing options...
Metalzoic Posted April 26, 2015 Share Posted April 26, 2015 I'm not sure what you mean. Isn't Keymapper just what you call the tab where you program in AHK, Joytokey, Xpadder etc...? Or are you saying there's an actual program called Keymapper? Link to comment Share on other sites More sharing options...
C_Wilson009 Posted April 29, 2015 Author Share Posted April 29, 2015 Hey I just got it to work for you! Use this line M & 5::send, {Escape}Seems to work. No idea why it needs the "&" symbol, but it seems to need the "send," command when changing to a special key like Escape. That does work.. However, it only seems to work with kega fusion for me so far. I tested that out with nestopia and nullDC and it doesn't seem to close either of them and go back to hyperspin Link to comment Share on other sites More sharing options...
beardydan Posted December 30, 2015 Share Posted December 30, 2015 Hi, I'd like to expand on this thread a bit, can't find anything else that's similar. First of all I think you'd be better off using this: ~M & ~5::Send, {escape} Return Tidies up the code and allows the keys to perform their normal function when not being used in a combination. I know this because I've been working on the same problem except with the 3 and 1 buttons. I've run into a very strange problem though that I think is being caused by Hyperlauch or how it interacts with AutoHotKey.You see if I use this code: ~3 & ~1::Send, {escape} Return I should be able to hold down 3 and when I hit 1 it should act like the escape key, and it does outside of game but in game it is the opposite (have to hold 1 and press 3). Switching the code around doesn't help, same result.Attached is a screenshot of my test out of game, it was tested within HyperlaunchHQ and worked fine as you can see. I tried a number of things: Restarted my machine (no change) Tried the key combination within a number of different emulators (same in each, combination is reversed) Reversing the code (no change) exclude the ~ from the code Used different peripherals to generate the keystrokes (keyboard, Tankstick) Unplugged the Tank stick and do a restart A real head scratcher. My next stop is to see if I can update Hyperlaunch without screwing everything up. Or perhaps Xpadder/DS4Windows is doing something funny? If anyone has an inkling of what might be going on please let me know, it's only a small thing but it's making my eye twitch! Link to comment Share on other sites More sharing options...
Metalzoic Posted December 30, 2015 Share Posted December 30, 2015 You're still using HyperLaunchHQ? I found that just updating to RocketLauncher fixed some of the AHK/Keymapper issues I was having before. I highly suggest you update to RocketLauncher anyway regardless of that though. I've found that using AHK through the Keymapper needs to be kept simple though. Like really simple as in just A::b or G::ESC simple. When I try to get more complex than that it seems to flat out not work. Most dupble key combos I've tried simply don't work in-game at all for some reason. What you're trying there doesn't seem to me that it would work through the Keymapper (Maybe if you removed everything fancy), but might need to be run outside of RocketLauncher (if it can be). Try simplifying it as much as possible, remove the tildes and the return, and try that. Another mention is that using the built in auto-mapper function in RLauncher seems to map the buttons backwards from what the instructions say. So best to manually type your script in (which I'm sure you are anyway). Good luck man. Link to comment Share on other sites More sharing options...
beardydan Posted December 30, 2015 Share Posted December 30, 2015 So what you're saying is I should update to RLauncher because it is even worse at handling AutoHotKey scripts? I hope you're not a salesman hahaha. Sent from my iPhone using Tapatalk Link to comment Share on other sites More sharing options...
Metalzoic Posted December 31, 2015 Share Posted December 31, 2015 Nope, overall they work better in RocketLauncher, but they still need to be kept simple. The backwards auto-mapping was in HyperLaunch too if I remember correctly. Link to comment Share on other sites More sharing options...
beardydan Posted January 2, 2016 Share Posted January 2, 2016 Right so I updated to RocketLauncher, that was a bit of fun lol. After some playing around I found my code above worked just fine. Better than expected actually, I put it under a default profile so it works in game too without needing fancy xpadder tricks. Sent from my iPhone using Tapatalk Link to comment Share on other sites More sharing options...
Metalzoic Posted January 4, 2016 Share Posted January 4, 2016 Right so I updated to RocketLauncher, that was a bit of fun lol. After some playing around I found my code above worked just fine. Better than expected actually, I put it under a default profile so it works in game too without needing fancy xpadder tricks. Sent from my iPhone using Tapatalk Sweet! I had noticed that AHK worked much better in RLauncher, but I still didn't think anything that tricky would work. Maybe I'll go back and retry a few things from the HL days then. Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.