MAMEWorld >> EmuChat
Index   Flat Mode Flat  

Mamesick
Troll Lamer
Reged: 09/21/03
Posts: 1649
Loc: Italy
Send PM
Re: Any way in mame to add a video file before game starts?
05/18/16 10:24 AM


It could be doable in MAMEUI(FX) due to its integration with the core:

- The user select a game after setup an interface option like "Play Game Video before emulation starts".
- A simple call to ShellExecute Windows API will launch the video associated to selected game name. Example: pacman.avi. This will open the associated video player like MPC-HC.
- Then execute the core commands to launch pacman as usual.

Main problem is I believe only how to tell to the video player to close itself automatically at the end of the video. I know VLC and MPC-HC have some command-line options to do this. Also, another problem could be create a loop waiting for the video to be played and finished, because ShellExecute will open another process and so RunMAME will be exuuted immediately after, while the video is still playing. I'm not sure of this, I should do a test.

Example of preliminary code:

Code:

If (PlayGameVideo)
ShellExecute(blah, blah, blah);
RunMAME(gamename);



Edited by Mamesick (05/18/16 10:27 AM)







Entire thread
Subject Posted by Posted on
* Any way in mame to add a video file before game starts? dracos2112 05/16/16 06:58 AM
. * Re: Any way in mame to add a video file before game starts? zambr  05/18/16 11:49 AM
. * First off, I'm the ultimate hero. Sheeez. ((:-)) Traso  05/17/16 12:27 AM
. * Re: Any way in mame to add a video file before game starts? Envisaged0ne  05/16/16 01:32 PM
. * Re: Any way in mame to add a video file before game starts? CiroConsentino  05/16/16 01:09 PM
. * Re: Any way in mame to add a video file before game starts? Mamesick  05/18/16 10:24 AM
. * Re: Any way in mame to add a video file before game starts? casm  05/17/16 02:15 AM
. * Re: Any way in mame to add a video file before game starts? uman  05/18/16 09:54 AM

Extra information Permissions
Moderator:  Robbbert, Tafoid 
0 registered and 226 anonymous users are browsing this forum.
You cannot start new topics
You cannot reply to topics
HTML is enabled
UBBCode is enabled
Thread views: 1919