Next Generation Emulation banner
1 - 3 of 3 Posts

·
Registered
Joined
·
146 Posts
Discussion Starter · #1 · (Edited)
This will .vbs script will open up your last played rom, and automatically place this in full screen with by just double clicking the "Desmume_Auto_Launcher.vbs" file. Like using a batch file, to run command line options ... a .vbs file uses windows script so its basically the same. Plus, we are inputing keystrokes automatically so and windows script supports this. Either download the "Desmume_Auto_Launcher.vbs" file from the .rar archive below. Or copy this script into a notepad .txt file, rename the file extension to .vbs and save the contents between the periods below to that file:

....................................
Set objShell = WScript.CreateObject("WScript.Shell")
objShell.Run "DeSmuME_0.9.10_x86.exe ––cpu-mode=15"
Wscript.Sleep 500
objShell.SendKeys "%"
Wscript.Sleep 500
objShell.SendKeys "F"
Wscript.Sleep 500
objShell.SendKeys "R"
Wscript.Sleep 500
objShell.SendKeys "{ENTER}"
Wscript.Sleep 500
objShell.SendKeys "%{ENTER}"
.....................................

"DeSmuME_0.9.10_X86.exe" is the name of your Desmume executable. You don't need to download any programs or any front ends to use this file. Windows Script is built into windows, I'm using Windows XP. "%" key is the "alt" key on your keyboard. And the "%{ENTER}" key is the fullscreen mode keys of "ALT + ENTER" for Desmume.

I read on a few forums about ppl making references to this, but nobody says how to, unfortunately, I had to take some time to figure out how, without downloading additional software or programs. ............. You edit the keys or change them to open up your rom directly or I guess, create a .vbs file to launch each game in your NDS library, rather then filtering through Desmume's Menu. Haven't tried through, and this will only auto launch in full screen your last recently opened rom, that you played in Desmume.
 

·
Registered
Joined
·
146 Posts
Discussion Starter · #2 · (Edited)
Auto Rom Launcher in Full Screen for Individual Rom, not a Recently Opened Rom

......................................
Set objShell = WScript.CreateObject("WScript.Shell")
objShell.Run "DeSmuME_0.9.10_x86.exe ––cpu-mode=15"
Wscript.Sleep 500
objShell.SendKeys "%"
Wscript.Sleep 500
objShell.SendKeys "F"
Wscript.Sleep 500
objShell.SendKeys "O"
Wscript.Sleep 500
objShell.SendKeys "C:\Documents and Settings\Admin\Desktop\NDS Roms\RPG\Disgaea DS.nds"
Wscript.Sleep 500
objShell.SendKeys "{ENTER}"
Wscript.Sleep 500
objShell.SendKeys "%{ENTER}"
.........................................

In this example, I've created a .vbs file to open just the .nds rom I specified. You must change the file path, to the path of the rom in parenthesis from "C:\Documents and Settings\Admin\Desktop\NDS Roms\RPG\Disgaea DS.nds", to the location of your .nds rom.

... ... Yes you could create a .batch file to auto create a .vbs file to launch each of your .nds roms individually, and specify the path of the file in each newly created .vbs file. This way all you'd have to do is double click the .vbs file to play your game instead of dealing with Desmume's menus each time to launch a game. ... ... I'll try to include an example from a precious .batch renamer file I used with Mame Rom Center some time ago, maybe later, but it won't be a perfect example.

(I don't think I can use vbscript to create a wide screen solution for Desmume, but you can stretch a windowed version of Desmume like its being stretched for widescreen, so I guess I'll just try a few things when I get the time to)
 

·
Registered
Joined
·
146 Posts
Discussion Starter · #3 · (Edited)
FIXED* Desmume Auto Launcher Full Screen + File Select

This vbscript will allow you to just use this one script to auto launch Desmume, and select any game you want to play before it switches Desmume to Full Screen. You can leave this on your desktop instead of the Desmume Icon.

...............................
Set objShell = WScript.CreateObject("WScript.Shell")
objShell.Run "DeSmuME_0.9.10_x86.exe ––cpu-mode=15"
Wscript.Sleep 1000
objShell.SendKeys "%"
Wscript.Sleep 1000
objShell.SendKeys "F"
Wscript.Sleep 1000
objShell.SendKeys "0"
Wscript.Sleep 1000
objShell.SendKeys "{ENTER}"
Wscript.Sleep 15000
objShell.SendKeys "%{ENTER}"
...............................

There's no shortcut to Desmume on my desktop there is only this shortcut I've created to this .vbs file which is inside the Desmume program folder.

Desmume saves the location of your "roms folder", so when the program launches it will open up this window (and in 15000 or 15 seconds, it will go to fullscreen), then after you select the NDS Game you want to play and press enter, the game will play a little bit before switching to fullscreen. If you need to give yourself more time to select a NDS Game to play then increase the time to 30000 or 30 seconds before the final full screen command "%{ENTER}" is given to desmume

Remember! You need to disable the "Tool Bar", click "View" then uncheck "Toolbar", then you will see the Full, Full Screen Mode.

Sorry about the triple post, but this should make things easier for people who want to do different things with Desmume. ... ... ...

Create a Romlist.txt file from batch listing all the files in the current drive
................
ECHO on
dir /b "%cd%" > romlist.txt
PAUSE
................

Create a "Desmume Auto Launcher for Each individual Rom" using batch
................
ECHO on
for /f "tokens=*" %%l in (romlist.txt) do @Type "Desmume_Auto_Launcher_Single Rom.vbs">> "%%l.vbs"
PAUSE
................

("Desmume_Auto_Launcher_Single Rom.vbs" is simply the .vbs file from post# 2, it must be in the directory along with romlist.txt to create a .vbs file for each of the files listed in romlist.txt)

Those were my old mame tools, however you can use vbscript to enter the file path, and the name, pulled from the extension, if you want to keep each rom file in its own folder with a .vbscript auto launcher ... ... to help save you the time of auto naming each file patch for each rom.

Not sure how to do that exactly but it can be done, based on what i've read from google, if you want to do that, but I think just using this .vbscript in this post is much simpler.
 

Attachments

1 - 3 of 3 Posts
Top