JemyM wrote:I have teamed up with
pycur to produce a library for D-Fend Reloaded, making DOS-games as accessible as frontends like
MAMEUI (arcadegames),
Gamebase 64 (Commodore 64) and
FS-UAE (Amiga).
What it looks likeThe goal is to build a library of preconfigurations with snapshots. To accomplish this we test all sorts of titles, examine their content, test them, determine the name of the executable and setup, find the cycles, set proper audiocards and capture snapshots if needed etc. If you are interested in helping out, drop pycur an e-mail at robotkuutya at gmail.com.
If I'm understanding this correctly; you're modding D-Fend Reloaded to allow for the addition of MAME and other games? So in other words, in addition to being able to add a DOSBox and ScummVM profile, you'll be able to add a MAME profile, among others?
On a somewhat unrelated subject, I just wanted to share with everyone some AutoHotkey scripts I wrote which give more control over the launching of ScummVM games from within D-Fend Reloaded. These are all compiled AutoHotkey scripts which are then added to D-Fend Reloaded as a "Windows" game (which simply allows you to launch any given .exe)
monkey-vga.exe - This is launched directly from D-Fend Reloaded as a windows game profile
- Code: Select all
#NoTrayIcon
#NoEnv ; Recommended for performance and compatibility with future AutoHotkey releases.
; #Warn ; Enable warnings to assist with detecting common errors.
SendMode Input ; Recommended for new scripts due to its superior speed and reliability.
SetWorkingDir %A_ScriptDir%\..\..\..\ScummVM (1.10.0) ; Ensures a consistent starting directory.
RunWait, "..\MT-32 ScummVM.exe"
Sleep, 1500
Run, ".\scummvm.exe" "--no-console" "--config=.\scummvm.ini" "monkey-vga"
Process, Wait, scummvm.exe, 5
Process, Exist, scummvm.exe
ScummVM = %ErrorLevel%
if ScummVM != 0
{
Run, "..\AutoHotkey Scripts\4x.exe"
Run, "..\AutoHotkey Scripts\mouse lock.exe"
Process, WaitClose, scummvm.exe
Run, "..\kill.exe"
} else {
MsgBox ScummVM was unable to start
}
return
What I do is add the game to D-Fend Reloaded as a "Windows" game, and choose this compiled AutoHotkey script as the executable. The other executables that this script references do different things.
MT-32 ScummVM.exe - Starts Falcosoft Midi Player withMT-32 ScummVM preset
- Code: Select all
#NoTrayIcon
#NoEnv ; Recommended for performance and compatibility with future AutoHotkey releases.
; #Warn ; Enable warnings to assist with detecting common errors.
SendMode Input ; Recommended for new scripts due to its superior speed and reliability.
SetWorkingDir %A_ScriptDir%\Sound\FSMP ; Ensures a consistent starting directory.
SetTitleMatchMode, 2
Loop = 0
MidiPlayer = 0
while Loop <= 1
{
Process, Exist, midiplayer.exe
MidiPlayer = %ErrorLevel%
if Midiplayer = 0
{
Run, ".\midiplayer.exe" ""-minimized -preset 002""
Process, Wait, midiplayer.exe, 2
Loop := Loop + 1
} else {
break
}
}
if Midiplayer = 0
{
MsgBox MT-32 was unable to start
}
return
4x.exe - Scales the game window to 1280x960, or, generally speaking, 4x its native resolution (which for most games, is not supported by ScummVM). For Monkey Island 3, this acts as a 2x scaler because its native resolution is larger than other games.
- Code: Select all
#NoTrayIcon
#NoEnv ; Recommended for performance and compatibility with future AutoHotkey releases.
; #Warn ; Enable warnings to assist with detecting common errors.
SendMode Input ; Recommended for new scripts due to its superior speed and reliability.
SetWorkingDir %A_ScriptDir%\..\..\..\ScummVM (1.10.0) ; Ensures a consistent starting directory.
Process, Wait, scummvm.exe, 5
Process, Exist, scummvm.exe
ScummVM = %ErrorLevel%
if ScummVM != 0
{
Sleep, 2000
WinMove, ahk_exe scummvm.exe, , 0, 0, 1296, 999
; Sleep, 100
; CenterWindow("ahk_exe scummvm.exe")
} else {
MsgBox ScummVM was unable to start
}
return
; The following function centers the specified window on the screen:
CenterWindow(WinTitle)
{
WinGetPos,,, Width, Height, %WinTitle%
WinMove, %WinTitle%,, (A_ScreenWidth/2)-(Width/2), (A_ScreenHeight/2)-(Height/2)
}
mouse lock.exe - Automatically locks the mouse to the ScummVM game window first receives focus (also not natively supported by ScummVM)
- Code: Select all
#NoTrayIcon
#NoEnv ; Recommended for performance and compatibility with future AutoHotkey releases.
; #Warn ; Enable warnings to assist with detecting common errors.
SendMode Input ; Recommended for new scripts due to its superior speed and reliability.
SetWorkingDir %A_ScriptDir% ; Ensures a consistent starting directory.
Sleep, 2000
WinActivate, ahk_class Shell_TrayWnd
WinWaitActive, ahk_exe scummvm.exe
Lock:
{
Send {Ctrl down}
Sleep, 10
Send m
Sleep, 10
Send {Ctrl up}
}
return
I want to keep working on mouse lock a bit so that it will continue to run even if the game window loses focus, and re-lock the cursor to the window once more when it receives focus (until the game is closed). I also want to add a function which will lock-unlock the cursor using ctrl+F10 in addition to ctrl+m (to mirror DOSBox functionality).
One of the main advantages to launching a game in this way is that it gives you the ability to launch things in order while being able to wait a precise amount of time between commands. This is especially useful to ensure that Falcosoft Midi Player is fully initialized before the game launches. Otherwise, this is just a bunch of quality of life stuff. I'm putting together a portable collection of my favorite games using D-Fend Reloaded and focusing on aesthetics and ease-of-use.
Here's a
demonstration of all these scripts working together to create a very seamless experience for the user. Here's what happens:
1. Falcosoft Midi Player is first launched by referencing a preset configured for Munt MT-32 VST (watch the taskbar during the video demo)
2. Game is launched
3. Game window is resized to 1280x960 (4x Monkey Island 1's native resolution)
4. Mouse automatically locks to game window upon first receiving focus
5. Falcosoft Midi Player is automatically closed when game is closed
As you can see, launching the desired game, fully-configured, is just a double-click away. By the way, my desktop resolution is 2650x1440. ScummVM natively only scales to 3x, which
looks fairly small on my monitor for games like Monkey Island 1 which have a native resolution of 320x240. At 1280x960 (or 4x), the game window is a
little more comfortable to view at my desktop resolution. The cool thing is that you can go higher if you want; just have to edit a couple numbers in the AutoHotkey script.