Public Types | |
enum | HostMode { HOST, OFFLINE, DEMO } |
Public Member Functions | |
GameRunner (const Server *server) | |
virtual bool | connectParameters (QStringList &args, PathFinder &pf, bool &iwadFound, const QString &connectPassword, const QString &wadTargetDirectory) |
Message | createHostCommandLine (const HostInfo &hostInfo, CommandLineInfo &cmdLine, HostMode mode) |
JoinError | createJoinCommandLine (CommandLineInfo &cli, const QString &connectPassword) |
Message | host (const HostInfo &hostInfo, HostMode mode) |
Message | runExecutable (const CommandLineInfo &cli, bool bWrapWithStandardServerConsole) |
Protected Member Functions | |
virtual QString | argForConnect () const |
Command line parameter that specifies the target server's IP and port. | |
virtual QString | argForConnectPassword () const |
Command line parameter that is used to specify connection password. | |
virtual QString | argForIwadLoading () const |
Command line parameter that is used to set IWAD. | |
virtual QString | argForPort () const |
Command line parameter that is used to set internet port for the game. | |
virtual QString | argForPwadLoading () const |
Command line parameter that is used to load a PWAD. | |
virtual QString | argForDemoPlayback () const |
Command line parameter for playing back a demo. | |
virtual QString | argForDemoRecord () const |
Command line parameter for recording a demo. | |
virtual QString | argForServerLaunch () const |
Command line parameter used to launch a server. | |
virtual Message | hostAppendIwad () |
virtual Message | hostAppendPwads () |
virtual Message | hostGetBinary (bool bOfflinePlay) |
virtual Message | hostGetWorkingDirectory (bool bOfflinePlay) |
virtual void | hostDMFlags (QStringList &args, const DMFlags &dmFlags) const |
virtual void | hostProperties (QStringList &args) const |
Protected Attributes | |
CommandLineInfo * | currentCmdLine |
const HostInfo * | currentHostInfo |
const Server * | server |
virtual QString GameRunner::argForConnectPassword | ( | ) | const [inline, protected, virtual] |
Command line parameter that is used to specify connection password.
There is no common value here so the default behavior returns a "null" string.
bool GameRunner::connectParameters | ( | QStringList & | args, |
PathFinder & | pf, | ||
bool & | iwadFound, | ||
const QString & | connectPassword, | ||
const QString & | wadTargetDirectory | ||
) | [virtual] |
Message GameRunner::createHostCommandLine | ( | const HostInfo & | hostInfo, |
CommandLineInfo & | cmdLine, | ||
HostMode | mode | ||
) |
[out] | cli | - after successful call this will contain required command line information. |
[out] | error | - if return == false, error text will be put here |
bOfflinePlay | - if not HOST a command line for single player game will be launched |
JoinError GameRunner::createJoinCommandLine | ( | CommandLineInfo & | cli, |
const QString & | connectPassword | ||
) |
[out] | cli | - after successful call this will contain required command line information. |
virtual void GameRunner::hostDMFlags | ( | QStringList & | args, |
const DMFlags & | dmFlags | ||
) | const [inline, protected, virtual] |
Creates engine specific command line parameters out of passed dmFlags list. Default behavior does nothing.
virtual void GameRunner::hostProperties | ( | QStringList & | args | ) | const [inline, protected, virtual] |
Creates engine specific command line parameters out of Server class fields.
Please note that port, and some other stuff, is already set by createHostCommandLine().
Message GameRunner::runExecutable | ( | const CommandLineInfo & | cli, |
bool | bWrapWithStandardServerConsole | ||
) |
Executes predefined command line.
cli | - command line that will be executed |
bWrapWithStandardServerConsole | - if true Doomseeker will attempt to wrap the input/output of the program with it's own console |