ckp Posted October 17, 2016 Share Posted October 17, 2016 Any ahk code I put inside the ahk tab for an emulator (Demul in my test), does not run. The prepopulated close startup app part of the script in that tab seems to be working. But for any other ahk code I use, it seems to be ignored. I can't run a program (like nomousy) or even a test MsgBox. I am starting to wonder if only hotkey code works in there since I'm trying to run ahk code without a hotkey press. Or maybe this tab isn't for writing ahk code at all? Does it work for anyone out there? Quote Link to comment Share on other sites More sharing options...
ckp Posted October 17, 2016 Author Share Posted October 17, 2016 so, @Jason Carr confirmed this is a bug and should be fixed in the next beta. 1 Quote Link to comment Share on other sites More sharing options...
hoodlum54 Posted October 21, 2016 Share Posted October 21, 2016 Any update on this? I'm running 6.12 but none of my "send" functions are working. Is this still broken or did the syntax change or something rendering my old codes obsolete? Thanks! Quote Link to comment Share on other sites More sharing options...
DOS76 Posted October 21, 2016 Share Posted October 21, 2016 I thought it was fixed. Quote Link to comment Share on other sites More sharing options...
hoodlum54 Posted October 21, 2016 Share Posted October 21, 2016 (edited) So I'm not sure why it worked, but I searched the launchbox folder for any exe and changed it (launchbox), big box, scummm (or whatever) all to run as administrator and that sorted it out for now it seems. Very weird. Thanks for the reply. Edited October 21, 2016 by hoodlum54 Quote Link to comment Share on other sites More sharing options...
hoodlum54 Posted November 13, 2016 Share Posted November 13, 2016 So MAME AHK for me still isn't working. I have the following script in the AHK script box in launchbox, and when I press the numbers nothing happens. Its like it blocks the input and doesn't send anything in return. Very Strange. Any help would be amazing as it's something I've been struggling with for at least 2 weeks. 1:: Send 5 return 2:: Send 6 Send 2 return 3:: Send 7 Send 3 return 4:: Send 8 Send 4 return None of these work at all. Quote Link to comment Share on other sites More sharing options...
DOS76 Posted November 13, 2016 Share Posted November 13, 2016 (edited) why do you need an AHK scrpt for MAME any way you can go into MAME's setting and set up combo presses by hitting enter and the two buttons on your controller at the same time go to exit and hit enter then press your 2 buttons and you should be good to go. Actually re-reading your post I see that you are looking to do more than exit out of games so I see why you may need the script Edited November 13, 2016 by DOS76 Quote Link to comment Share on other sites More sharing options...
hoodlum54 Posted November 13, 2016 Share Posted November 13, 2016 Well I'm trying to make my player 1-4 start buttons first add 2 coins then hit start. This would allow all 7 non start buttons for players 1&2 and all 4 non start buttons for players 3&4 be mapped properly. So I thought the easiest way to do it would be AHK where it would send coins then start, but does it not work with MAME? All the other platforms it's working fine with. Thanks so much for the quick response. I'll try disabling the script and then changing MAME to do 2 coins per press and changing it so the button is also mapped to start. That's the best method then? Quote Link to comment Share on other sites More sharing options...
DOS76 Posted November 13, 2016 Share Posted November 13, 2016 Yeah I edited my post when I saw what you were trying to do with the button presses. I don't know if that is possible through MAME you may need to use a script. I've never thought of mapping start and coin to the same button that is actually an interesting idea Quote Link to comment Share on other sites More sharing options...
hoodlum54 Posted November 13, 2016 Share Posted November 13, 2016 (edited) Yeah I had it working by just configuring winipac to send a macro (5,5,1) for player 1 with 5 being coin for player 1, 1 being start for player 1. It worked great for MAME, but it was messing with any other games that needed to use that button (I have a save and a load button on the cabinet and was using player start buttons as numbers for save states. So I'd hit "save" and then hit 1 if the emulator doesn't support quick save - like Mame for instance.) And I didn't like the idea of sending excess keystrokes for no reason. If I can't figure out the script I'll probably just go back to macros with winipac and make sure that the extra strokes aren't set to numbers then and are not used in the emulator. I just thought it'd be easier with AHK. Edited November 13, 2016 by hoodlum54 Quote Link to comment Share on other sites More sharing options...
ckp Posted November 13, 2016 Author Share Posted November 13, 2016 You should check out this thread. It shows how to enable ahk for MAME. Search for this point "The key one to make the AHK inputs work is keyboardprovider. This option MUST be set to "dinput" (for DirectInput). Without this, MAME will not read the keystrokes coming from AHK." Hope this helps. Quote Link to comment Share on other sites More sharing options...
hoodlum54 Posted November 13, 2016 Share Posted November 13, 2016 @ckp thank you so, so much! That's exactly what I needed! I changed the ini file to use "dinput" and then also used the sleep function just to see if that'd help too. At first glance it seems to be working! I'll update again. Thanks so much to everyone! Quote Link to comment Share on other sites More sharing options...
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.