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: Two ideas already implemented: extra info screen and options on exit  (Read 2061 times)

0 Members and 1 Guest are viewing this topic.

Stormrider

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 318
  • Last login:September 28, 2014, 11:01:54 am




I think you can make an idea just be taking a look at these screens. Anyone interested in knowing how to do it, please tell me and I'll explain.

drventure

  • Trade Count: (+2)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 4152
  • Last login:April 23, 2024, 06:53:06 pm
  • Laser Death Ray Bargain Bin! Make me an offer!
Re: Two ideas already implemented: extra info screen and options on exit
« Reply #1 on: November 02, 2009, 06:08:21 pm »
Very interested in how you did it. Is it a custom plugin? or just some fancy config?

Stormrider

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 318
  • Last login:September 28, 2014, 11:01:54 am
Re: Two ideas already implemented: extra info screen and options on exit
« Reply #2 on: November 03, 2009, 05:01:29 pm »
Scripting with Autohotkey.

First, the script for the custom screen. Comments after the ;

#IfWinActive MaLa ahk_class TfrmMain ; checks that MaLa main menu is active
~1Joy2:: ; the joy button that will show the screen
IniRead, OutputVar, d:\mala\selection.ini, mame, Gamelist ; depending on the screen orientation (reading selection.ini)...
if OutputVar=verts
{
SoundPlay, d:\mala\2.wav ; plays the same sound I have to other menus
run, d:\mala\CPV2.exe -b=d:\mala\mameuiv.jpg ; and shows the custom screen (this one is the vertical screen)
return
}
else
{
SoundPlay, d:\mala\2.wav
run, d:\mala\CPV2.exe -b=d:\mala\mameuih.jpg
return
}

#IfWinActive CPV2 Viewer ahk_class ThunderRT6FormDC ; when the custom screen is displayed...
~1Joy2:: ; the same joy button sends a keystroke to cancel the viewer
SoundPlay, d:\mala\2.wav

---

and now the quit menu:

#IfWinActive ahk_class TfrmExit ; checks that the active screen is MaLa quit dialogue
~1joy4:: ; joy button assigned to the quit function
send, {Enter}
sleep 3000 ; pause for not showing garbage on screen
run, d:\mala\explorer-pointers.exe ; that's another script, which runs explorer.exe, bringing the desktop/windows environment, apart from other functions (pointers swap, boot screen rotation, etc). You can change this line with run,%windir%\explorer.exe You are supposed to be running MaLa from userinit instead of explorer.exe
return

#IfWinActive ahk_class TfrmExit
~1joy1:: ; button for shutting down
send, {Enter}
sleep 3000
run, d:\mala\qsd.exe -s ; program for silently shutting down your computer
exitapp

#IfWinActive ahk_class TfrmExit
~1joy8:: ; button for canceling the quit dialogue
send, {Esc}
return
send, 0
return