23 #include "gameexefactory.h"
25 #include "plugins/engineplugin.h"
26 #include "serverapi/exefile.h"
27 #include "serverapi/gamefile.h"
29 DClass<GameExeFactory>
34 QList<ExeFilePath>(
GameExeFactory::*additionalExecutables)(
int)
const;
44 set_additionalExecutables(&GameExeFactory::additionalExecutables_default);
45 set_gameFiles(&GameExeFactory::gameFiles_default);
48 GameExeFactory::~GameExeFactory()
52 POLYMORPHIC_DEFINE_CONST(QList<ExeFilePath>,
GameExeFactory, additionalExecutables, (
int execType), (execType))
60 QList<ExeFilePath> GameExeFactory::additionalExecutables_default(
int execType)
const
63 return QList<ExeFilePath>();
68 GameFile tmplate =
GameFile().setSearchSuffixes(d->plugin->data()->gameFileSearchSuffixes);
70 if (d->plugin->data()->clientOnly)
72 list <<
GameFile(tmplate).setConfigName(
"BinaryPath").setNiceName(tr(
"game"))
73 .setFileName(d->plugin->data()->clientExeName)
74 .setExecutable(GameFile::Cso);
78 list <<
GameFile(tmplate).setConfigName(
"BinaryPath").setNiceName(tr(
"client"))
79 .setFileName(d->plugin->data()->clientExeName)
80 .setExecutable(GameFile::Offline | GameFile::Client);
81 list <<
GameFile(tmplate).setConfigName(
"ServerBinaryPath").setNiceName(tr(
"server"))
82 .setFileName(d->plugin->data()->serverExeName).setExecutable(GameFile::Server);