From ZDoom Wiki
Jump to navigation Jump to search

int PlayMovie (str moviename)

Nuvolabomb.png Warning: The feature described on this page has been deprecated, and will no longer be supported or updated by the GZDoom developers. While some functionality may be retained for the purposes of backwards-compatibility, authors are strongly discouraged from utilizing this feature in future projects. Compatibility with future GZDoom versions is not guaranteed.

This command is disabled in current ZDoom version. It is very unlikely that it ever gets re-enabled. The function will just fail and return MOVIE_Failed.

The description below only applies to old ZDoom versions which still had this command working:


Plays a video file. This function uses DirectShow (the same media library that Windows Media Player uses), so it only works in Windows and it can play any files that WMP has the codecs for.

  • moviename is the filesystem address of the file, so if you have, say, blah.avi in the same directory as zdoom.exe you can do PlayMovie("blah.avi"), but you can also play any movie on the filesystem, so PlayMovie("c:\doom2\zdoom\blah.avi") would work as well.

Depending on how playback proceeds, one of the following values will be returned:

The movie was played through completely without problems.
The movie played, but the proper video codec was not installed, so it was audio-only.
The user quit movie playback by pressing the escape key before it could finish.
The movie could not play at all, either because no audio or video codec was available, or because the operating system is not Windows.

This is no longer available as a console command with the same name in the current version either.