#include <gamedemo.h>
Public Member Functions | |
QString | exportedName () const |
QString | exportedNameNoExtension () const |
bool | hasDemoFile () const |
void | imprintPath (const QString &path) |
QString | managedName () const |
QString | managedNameNoExtension () const |
Public Attributes | |
QString | author |
Who recorded this demo. | |
QString | demopath |
Path to the demo file this metadata describes. | |
QString | game |
The canonical name of the plugin for the game (port, engine) from which the demo was recorded. | |
QString | gameVersion |
The version of the game that was used to record the demo. | |
QString | iwad |
IWAD used to record this demo. | |
QDateTime | time |
Date and time when the demo was recorded. | |
QList< PWad > | wads |
PWADs and other game mod files used to record this demo. | |
Static Public Attributes | |
static const unsigned | MAX_AUTHOR_FILENAME_LEN = 32 |
The extra metadata that describes a recorded game demo.
Conveys the file path to the actual demo (demopath
) plus other information that help describe this demo: when it was recorded, what game it was, what files were loaded.
Definition at line 44 of file gamedemo.h.
QString GameDemo::exportedName | ( | ) | const |
The proposed demo name when exporting.
It's derived from game
, author
and time
, with some mangling done to them to ensure everything can be safely used in paths. The name doesn't contain path separators. The extension (suffix) is derived from demopath
.
Definition at line 174 of file gamedemo.cpp.
QString GameDemo::exportedNameNoExtension | ( | ) | const |
The same as exportedName() but without the file extension.
Definition at line 180 of file gamedemo.cpp.
|
inline |
True if this metadata relates to a file found somewhere on the disk.
Definition at line 97 of file gamedemo.h.
void GameDemo::imprintPath | ( | const QString & | path | ) |
Parse the path for metadata, addding any info that was found.
There are two filename formats for managed demos:
Game_03.07.2024_21.54.06[_wad1_wad2...].lmp
Player/2024/Game_2024-02-01T113721Z.lmp
And also there's an exported filename format that looks like this:
Player_Game_2024-02-01T113721.lmp
We shall do our best to read the information off them, but failing to do so is not the end of the world. Missing information is just that – missing. It's just not imprinted.
Definition at line 229 of file gamedemo.cpp.
QString GameDemo::managedName | ( | ) | const |
The name of the file when stored in Doomseeker's managed demos directory.
The name is for the use in DemoStore. It's derived from game
, author
and time
, with some mangling done to them to ensure everything can be safely used in paths. The name may contain some path separators that DemoStore uses for better organization. The extension (suffix) is derived from demopath
.
Definition at line 201 of file gamedemo.cpp.
QString GameDemo::managedNameNoExtension | ( | ) | const |
The same as managedName() but without the file extension.
Definition at line 207 of file gamedemo.cpp.
QString GameDemo::author |
Who recorded this demo.
Definition at line 51 of file gamedemo.h.
QString GameDemo::demopath |
Path to the demo file this metadata describes.
Definition at line 49 of file gamedemo.h.
QString GameDemo::game |
The canonical name of the plugin for the game (port, engine) from which the demo was recorded.
Definition at line 53 of file gamedemo.h.
QString GameDemo::gameVersion |
The version of the game that was used to record the demo.
Definition at line 55 of file gamedemo.h.
QString GameDemo::iwad |
IWAD used to record this demo.
Definition at line 59 of file gamedemo.h.
QDateTime GameDemo::time |
Date and time when the demo was recorded.
Definition at line 57 of file gamedemo.h.
QList<PWad> GameDemo::wads |
PWADs and other game mod files used to record this demo.
Definition at line 61 of file gamedemo.h.