- allow selecting frontend for Duke3D in gameinfo.txt

This commit is contained in:
Christoph Oelckers 2020-03-07 20:14:03 +01:00
parent 68f249873c
commit 93eea97477
4 changed files with 21 additions and 11 deletions

View file

@ -333,10 +333,14 @@ void CheckFrontend(int flags)
{ {
gi = Powerslave::CreateInterface(); gi = Powerslave::CreateInterface();
} }
else if (flags & GAMEFLAG_FURY) else if ((flags & GAMEFLAG_FURY) || RazeStartupInfo.modern > 0)
{ {
gi = Duke::CreateInterface(); gi = Duke::CreateInterface();
} }
else if (RazeStartupInfo.modern < 0)
{
gi = Redneck::CreateInterface();
}
else else
{ {
gi = *duke_compatibility_15 ? Redneck::CreateInterface() : Duke::CreateInterface(); gi = *duke_compatibility_15 ? Redneck::CreateInterface() : Duke::CreateInterface();

View file

@ -170,6 +170,7 @@ struct FStartupInfo
FString Name; FString Name;
uint32_t FgColor; // Foreground color for title banner uint32_t FgColor; // Foreground color for title banner
uint32_t BkColor; // Background color for title banner uint32_t BkColor; // Background color for title banner
int modern;
//FString Song; //FString Song;
//int Type; //int Type;
//int LoadLights = -1; //int LoadLights = -1;

View file

@ -361,6 +361,11 @@ static FString ParseGameInfo(TArray<FString>& pwads, const char* fn, const char*
sc.MustGetString(); sc.MustGetString();
RazeStartupInfo.BkColor = V_GetColor(NULL, sc); RazeStartupInfo.BkColor = V_GetColor(NULL, sc);
} }
else if (!nextKey.CompareNoCase("MODERN"))
{
sc.MustGetNumber();
RazeStartupInfo.modern = sc.Number ? 1 : -1;
}
else else
{ {
// Silently ignore unknown properties // Silently ignore unknown properties

View file

@ -66,17 +66,17 @@ const char *GetVersionString();
#define SAVESIG_SW GAMENAME ".ShadowWarrior" #define SAVESIG_SW GAMENAME ".ShadowWarrior"
#define SAVESIG_PS GAMENAME ".Exhumed" #define SAVESIG_PS GAMENAME ".Exhumed"
#define MINSAVEVER_DN3D 4 #define MINSAVEVER_DN3D 6
#define MINSAVEVER_BLD 5 #define MINSAVEVER_BLD 6
#define MINSAVEVER_RR 5 #define MINSAVEVER_RR 6
#define MINSAVEVER_SW 3 #define MINSAVEVER_SW 6
#define MINSAVEVER_PS 3 #define MINSAVEVER_PS 6
#define SAVEVER_DN3D 4 #define SAVEVER_DN3D 6
#define SAVEVER_BLD 5 #define SAVEVER_BLD 6
#define SAVEVER_RR 5 #define SAVEVER_RR 6
#define SAVEVER_SW 3 #define SAVEVER_SW 6
#define SAVEVER_PS 3 #define SAVEVER_PS 6
#if defined(__APPLE__) || defined(_WIN32) #if defined(__APPLE__) || defined(_WIN32)
#define GAME_DIR GAMENAME #define GAME_DIR GAMENAME