Main Restorations Software Audio/Jukebox/MP3 Everything Else Buy/Sell/Trade
Project Announcements Monitor/Video GroovyMAME Merit/JVL Touchscreen Meet Up Retail Vendors
Driving & Racing Woodworking Software Support Forums Consoles Project Arcade Reviews
Automated Projects Artwork Frontend Support Forums Pinball Forum Discussion Old Boards
Raspberry Pi & Dev Board controls.dat Linux Miscellaneous Arcade Wiki Discussion Old Archives
Lightguns Arcade1Up Try the site in https mode Site News

Unread posts | New Replies | Recent posts | Rules | Chatroom | Wiki | File Repository | RSS | Submit news

  

Author Topic: Mala Pre / Post Commands  (Read 5713 times)

0 Members and 1 Guest are viewing this topic.

markronz

  • We traced the call, and it came from....INSIDE YOUR ARCADE MACHINE!
  • Trade Count: (+1)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 821
  • Last login:April 12, 2019, 12:03:08 am
  • Game on!
Mala Pre / Post Commands
« on: January 20, 2011, 10:27:23 am »
Please see my attached screen shot.   Is this the correct way to configure Mala's Pre and Post commands?     Theres a known problem where the mouse cursor flashes when launching nestopia.  So I was attemping to use this nomousy.exe tool to hide the mouse cursor.   However, when I run it, as i have it set up now, the pre and post commands sometimes seem to freeze on the screen.  I've attached another screenshot of the post command froze on the screen.   Any idea why this would be happening?   The pre command does seem to execute, and the mouse cursor is hidden.   But the post command just locks up Mala like this.  Any idea whats up?  Do I have anything not set up correctly?

markronz

  • We traced the call, and it came from....INSIDE YOUR ARCADE MACHINE!
  • Trade Count: (+1)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 821
  • Last login:April 12, 2019, 12:03:08 am
  • Game on!
Re: Mala Pre / Post Commands
« Reply #1 on: January 20, 2011, 03:16:53 pm »
Ok, I have been playing with this a bit more.   It seems that the problem is directly linked to the nomousy.exe executable (attached here).    From what I can tell, the nomousy.exe file runs VERY quickly and then exits.  It seems that Mala is too slow maybe to realize that it did in fact run?    The reason I say this is, I changed the POST command to launch the windows calculator instead.   When I did this, the same "Post Command #1" screen came up.    It also froze there.   That is, it froze until I exited the calculator.   So it appears that screen is waiting for the launched executable to close.   Hopefully that makes sense.   So when I run the Post Command #1 on nomousy.exe it is apparently sitting there to wait for it to exit, even though it has already ran and completed already.

Now I was able to work around this.  The only thing I did was wrap the exe inside a batch file.  And I set my pre/post commands to launch my batch file, instead of the executable.

So my batch file simply says this in it:
Code: [Select]
start "nomousy" "C:\Emulators\nomousy.exe" /h
Exit

That solves my problem.   There is one downfall to doing it this way however.   Due to the nature of batch files...a dos window does flash on the screen when the batch file runs.   I'd really rather this not happen, if I can avoid it.   I wish there was a "hidden" option for batch files...

Anyway, loadman, let me know if you have any ideas on how to fix this.   I guess I'd like to either find a way to run that batch file and keep the dos window hidden, or else just correctly launch the exe file during the pre/post commands.    Let me know what you think!
« Last Edit: January 20, 2011, 04:42:44 pm by markronz »

markronz

  • We traced the call, and it came from....INSIDE YOUR ARCADE MACHINE!
  • Trade Count: (+1)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 821
  • Last login:April 12, 2019, 12:03:08 am
  • Game on!
Re: Mala Pre / Post Commands
« Reply #2 on: January 20, 2011, 04:38:43 pm »
OK, so I have figured out one way to make this work myself.   Let me tell you how I did it, just in the off chance someone else wants to do this some day...

First I downloaded this hidden start program.  This allows you to launch bat files and keep the resulting Command windows hidden:
http://www.ntwind.com/software/utilities/hstart.html

Then I downloaded this nomousy executable that someone made to temporarily hide the mouse cursor:
http://www.autohotkey.com/forum/topic2197.html

Then I made a batch file, with the following code in it:
Code: [Select]
start "nomousy" "C:\Emulators\nomousy.exe" /h
Exit

Then I set my pre and post commands for my Nintendo emulator in Mala to look like the following:
Code: [Select]
C:\Emulators\hstart.exe /NOCONSOLE "C:\Emulators\nomousy.bat"There is a screenshot of this attached below.

And it works!  Every time I launch a Nintendo game, it runs my batch file, hidden so no cmd windows pop up, and it hides the mouse from view in Nestopia.  So you don't see that unsettling mouse cursor when you launch a game.

Then when you exit the game, the script launches again, hidden again, and makes the mouse cursor reappear.

I did this because I didn't want to permanently get rid of the mouse cursor.  I still use it for administrative type stuff.   The only time I did see it when I didn't want to, was when opening Nestopia.   So I'm very happy its working now!

Loadman, if you still want to look into why the pre and post commands couldn't simply run the exe like normal, please let me know and I'd be happy to help test.  My guess is that you'd be able to duplicate the problem on your end however.