mirror of
https://github.com/ZDoom/gzdoom.git
synced 2024-11-26 05:51:20 +00:00
- removed gamemission variable because it wasn't used anywhere.
- removed gamemode variable. All it was used for were some checks that really should depend on GI_MAPxx. - Externalized all internal gameinfo definitions. - added include to MAPINFO parser. - split IWAD detection code off from d_main.cpp into its own file. - disabled gamemission based switch filtering because it is not useful. - added GAMEINFO submission by Blzut3 with significant modifications. There is no GAMEINFO lump. Instead all information is placed in MAPINFO, except the data that is needed to decide which WADs to autoload. SVN r1497 (trunk)
This commit is contained in:
parent
81f834e3f4
commit
505031fa5a
33 changed files with 896 additions and 1729 deletions
|
@ -1,4 +1,15 @@
|
||||||
March 19, 2009
|
March 22, 2009 (Changes by Graf Zahl)
|
||||||
|
- removed gamemode variable. All it was used for were some checks that
|
||||||
|
really should depend on GI_MAPxx.
|
||||||
|
- Externalized all internal gameinfo definitions.
|
||||||
|
- added include to MAPINFO parser.
|
||||||
|
- split IWAD detection code off from d_main.cpp into its own file.
|
||||||
|
- disabled gamemission based switch filtering because it is not useful.
|
||||||
|
- added GAMEINFO submission by Blzut3 with significant modifications. There
|
||||||
|
is no GAMEINFO lump. Instead all information is placed in MAPINFO, except
|
||||||
|
the data that is needed to decide which WADs to autoload.
|
||||||
|
|
||||||
|
March 19, 2009
|
||||||
- Added the current value of the string buffer to the state saved when
|
- Added the current value of the string buffer to the state saved when
|
||||||
making a function call in ACS. Now you can print inside functions and
|
making a function call in ACS. Now you can print inside functions and
|
||||||
also return values from them for the caller to plug directly into
|
also return values from them for the caller to plug directly into
|
||||||
|
|
661
src/d_main.cpp
661
src/d_main.cpp
|
@ -117,6 +117,7 @@ extern void R_ExecuteSetViewSize ();
|
||||||
extern void G_NewInit ();
|
extern void G_NewInit ();
|
||||||
extern void SetupPlayerClasses ();
|
extern void SetupPlayerClasses ();
|
||||||
extern bool CheckCheatmode ();
|
extern bool CheckCheatmode ();
|
||||||
|
extern const IWADInfo *D_FindIWAD(const char *basewad);
|
||||||
|
|
||||||
// PUBLIC FUNCTION PROTOTYPES ----------------------------------------------
|
// PUBLIC FUNCTION PROTOTYPES ----------------------------------------------
|
||||||
|
|
||||||
|
@ -124,7 +125,6 @@ void D_CheckNetGame ();
|
||||||
void D_ProcessEvents ();
|
void D_ProcessEvents ();
|
||||||
void G_BuildTiccmd (ticcmd_t* cmd);
|
void G_BuildTiccmd (ticcmd_t* cmd);
|
||||||
void D_DoAdvanceDemo ();
|
void D_DoAdvanceDemo ();
|
||||||
void D_AddFile (const char *file);
|
|
||||||
void D_AddWildFile (const char *pattern);
|
void D_AddWildFile (const char *pattern);
|
||||||
|
|
||||||
// PRIVATE FUNCTION PROTOTYPES ---------------------------------------------
|
// PRIVATE FUNCTION PROTOTYPES ---------------------------------------------
|
||||||
|
@ -145,22 +145,6 @@ EXTERN_CVAR (Int, screenblocks)
|
||||||
EXTERN_CVAR (Bool, sv_cheats)
|
EXTERN_CVAR (Bool, sv_cheats)
|
||||||
EXTERN_CVAR (Bool, sv_unlimited_pickup)
|
EXTERN_CVAR (Bool, sv_unlimited_pickup)
|
||||||
|
|
||||||
extern gameinfo_t SharewareGameInfo;
|
|
||||||
extern gameinfo_t RegisteredGameInfo;
|
|
||||||
extern gameinfo_t RetailGameInfo;
|
|
||||||
extern gameinfo_t CommercialGameInfo;
|
|
||||||
extern gameinfo_t HereticGameInfo;
|
|
||||||
extern gameinfo_t HereticSWGameInfo;
|
|
||||||
extern gameinfo_t HexenGameInfo;
|
|
||||||
extern gameinfo_t HexenDKGameInfo;
|
|
||||||
extern gameinfo_t StrifeGameInfo;
|
|
||||||
extern gameinfo_t StrifeTeaserGameInfo;
|
|
||||||
extern gameinfo_t StrifeTeaser2GameInfo;
|
|
||||||
extern gameinfo_t ChexGameInfo;
|
|
||||||
extern gameinfo_t Chex3GameInfo;
|
|
||||||
extern gameinfo_t PlutoniaGameInfo;
|
|
||||||
extern gameinfo_t TNTGameInfo;
|
|
||||||
|
|
||||||
extern int testingmode;
|
extern int testingmode;
|
||||||
extern bool setmodeneeded;
|
extern bool setmodeneeded;
|
||||||
extern bool netdemo;
|
extern bool netdemo;
|
||||||
|
@ -194,8 +178,6 @@ CUSTOM_CVAR (Int, fraglimit, 0, CVAR_SERVERINFO)
|
||||||
}
|
}
|
||||||
|
|
||||||
CVAR (Float, timelimit, 0.f, CVAR_SERVERINFO);
|
CVAR (Float, timelimit, 0.f, CVAR_SERVERINFO);
|
||||||
CVAR (Bool, queryiwad, true, CVAR_ARCHIVE|CVAR_GLOBALCONFIG);
|
|
||||||
CVAR (String, defaultiwad, "", CVAR_ARCHIVE|CVAR_GLOBALCONFIG);
|
|
||||||
CVAR (Int, wipetype, 1, CVAR_ARCHIVE);
|
CVAR (Int, wipetype, 1, CVAR_ARCHIVE);
|
||||||
CVAR (Int, snd_drawoutput, 0, 0);
|
CVAR (Int, snd_drawoutput, 0, 0);
|
||||||
|
|
||||||
|
@ -219,84 +201,12 @@ FTexture *Advisory;
|
||||||
|
|
||||||
cycle_t FrameCycles;
|
cycle_t FrameCycles;
|
||||||
|
|
||||||
// If autoname is NULL, that's either because that game doesn't allow
|
|
||||||
// loading of external wads or because it's already caught by the
|
|
||||||
// general game-specific wads section.
|
|
||||||
const IWADInfo IWADInfos[NUM_IWAD_TYPES] =
|
|
||||||
{
|
|
||||||
// banner text, autoname, fg color, bg color
|
|
||||||
{ "Final Doom: TNT - Evilution", "TNT", MAKERGB(168,0,0), MAKERGB(168,168,168) },
|
|
||||||
{ "Final Doom: Plutonia Experiment", "Plutonia", MAKERGB(168,0,0), MAKERGB(168,168,168) },
|
|
||||||
{ "Hexen: Beyond Heretic", NULL, MAKERGB(240,240,240), MAKERGB(107,44,24) },
|
|
||||||
{ "Hexen: Deathkings of the Dark Citadel", "HexenDK", MAKERGB(240,240,240), MAKERGB(139,68,9) },
|
|
||||||
{ "Hexen: Demo Version", "HexenDemo",MAKERGB(240,240,240), MAKERGB(107,44,24) },
|
|
||||||
{ "DOOM 2: Hell on Earth", "Doom2", MAKERGB(168,0,0), MAKERGB(168,168,168) },
|
|
||||||
{ "Heretic Shareware", NULL, MAKERGB(252,252,0), MAKERGB(168,0,0) },
|
|
||||||
{ "Heretic: Shadow of the Serpent Riders", NULL, MAKERGB(252,252,0), MAKERGB(168,0,0) },
|
|
||||||
{ "Heretic", NULL, MAKERGB(252,252,0), MAKERGB(168,0,0) },
|
|
||||||
{ "DOOM Shareware", NULL, MAKERGB(168,0,0), MAKERGB(168,168,168) },
|
|
||||||
{ "The Ultimate DOOM", "Doom1", MAKERGB(84,84,84), MAKERGB(168,168,168) },
|
|
||||||
{ "DOOM Registered", "Doom1", MAKERGB(84,84,84), MAKERGB(168,168,168) },
|
|
||||||
{ "Strife: Quest for the Sigil", NULL, MAKERGB(224,173,153), MAKERGB(0,107,101) },
|
|
||||||
{ "Strife: Teaser (Old Version)", NULL, MAKERGB(224,173,153), MAKERGB(0,107,101) },
|
|
||||||
{ "Strife: Teaser (New Version)", NULL, MAKERGB(224,173,153), MAKERGB(0,107,101) },
|
|
||||||
{ "Freedoom", "Freedoom", MAKERGB(50,84,67), MAKERGB(198,220,209) },
|
|
||||||
{ "Freedoom \"Demo\"", "Freedoom1",MAKERGB(50,84,67), MAKERGB(198,220,209) },
|
|
||||||
{ "FreeDM", "FreeDM", MAKERGB(50,84,67), MAKERGB(198,220,209) },
|
|
||||||
{ "Chex(R) Quest", "Chex", MAKERGB(255,255,0), MAKERGB(0,192,0) },
|
|
||||||
{ "Chex(R) Quest 3", "Chex3", MAKERGB(255,255,0), MAKERGB(0,192,0) },
|
|
||||||
};
|
|
||||||
|
|
||||||
// PRIVATE DATA DEFINITIONS ------------------------------------------------
|
// PRIVATE DATA DEFINITIONS ------------------------------------------------
|
||||||
|
|
||||||
static wadlist_t **wadtail = &wadfiles;
|
static wadlist_t **wadtail = &wadfiles;
|
||||||
static int demosequence;
|
static int demosequence;
|
||||||
static int pagetic;
|
static int pagetic;
|
||||||
static const char *IWADNames[] =
|
|
||||||
{
|
|
||||||
NULL,
|
|
||||||
"doom2f.wad",
|
|
||||||
"doom2.wad",
|
|
||||||
"plutonia.wad",
|
|
||||||
"tnt.wad",
|
|
||||||
"doomu.wad", // Hack from original Linux version. Not necessary, but I threw it in anyway.
|
|
||||||
"doom.wad",
|
|
||||||
"doom1.wad",
|
|
||||||
"heretic.wad",
|
|
||||||
"heretic1.wad",
|
|
||||||
"hexen.wad",
|
|
||||||
"hexdd.wad",
|
|
||||||
"hexendemo.wad",
|
|
||||||
"hexdemo.wad",
|
|
||||||
"strife1.wad",
|
|
||||||
"strife0.wad",
|
|
||||||
"freedoom.wad", // Freedoom.wad is distributed as Doom2.wad, but this allows to have both in the same directory.
|
|
||||||
"freedoom1.wad",
|
|
||||||
"freedm.wad",
|
|
||||||
"chex.wad",
|
|
||||||
"chex3.wad",
|
|
||||||
#ifdef unix
|
|
||||||
"DOOM2.WAD", // Also look for all-uppercase names
|
|
||||||
"PLUTONIA.WAD",
|
|
||||||
"TNT.WAD",
|
|
||||||
"DOOM.WAD",
|
|
||||||
"DOOM1.WAD",
|
|
||||||
"HERETIC.WAD",
|
|
||||||
"HERETIC1.WAD",
|
|
||||||
"HEXEN.WAD",
|
|
||||||
"HEXDD.WAD",
|
|
||||||
"HEXENDEMO.WAD",
|
|
||||||
"HEXDEMO.WAD",
|
|
||||||
"STRIFE1.WAD",
|
|
||||||
"STRIFE0.WAD",
|
|
||||||
"FREEDOOM.WAD",
|
|
||||||
"FREEDOOM1.WAD",
|
|
||||||
"FREEDM.WAD",
|
|
||||||
"CHEX.WAD",
|
|
||||||
"CHEX3.WAD",
|
|
||||||
#endif
|
|
||||||
NULL
|
|
||||||
};
|
|
||||||
|
|
||||||
// CODE --------------------------------------------------------------------
|
// CODE --------------------------------------------------------------------
|
||||||
|
|
||||||
|
@ -1215,11 +1125,8 @@ void D_DoAdvanceDemo (void)
|
||||||
case 2:
|
case 2:
|
||||||
pagetic = (int)(gameinfo.pageTime * TICRATE);
|
pagetic = (int)(gameinfo.pageTime * TICRATE);
|
||||||
gamestate = GS_DEMOSCREEN;
|
gamestate = GS_DEMOSCREEN;
|
||||||
if (pagecount == 0)
|
pagename = gameinfo.creditPages[pagecount];
|
||||||
pagename = gameinfo.creditPage1;
|
pagecount = (pagecount+1) % gameinfo.creditPages.Size();
|
||||||
else
|
|
||||||
pagename = gameinfo.creditPage2;
|
|
||||||
pagecount ^= 1;
|
|
||||||
demosequence = 1;
|
demosequence = 1;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
@ -1429,555 +1336,6 @@ static void D_AddDirectory (const char *dir)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
//==========================================================================
|
|
||||||
//
|
|
||||||
// SetIWAD
|
|
||||||
//
|
|
||||||
// Sets parameters for the game using the specified IWAD.
|
|
||||||
//==========================================================================
|
|
||||||
|
|
||||||
static void SetIWAD (const char *iwadpath, EIWADType type)
|
|
||||||
{
|
|
||||||
static const struct
|
|
||||||
{
|
|
||||||
GameMode_t Mode;
|
|
||||||
const gameinfo_t *Info;
|
|
||||||
GameMission_t Mission;
|
|
||||||
} Datas[NUM_IWAD_TYPES] = {
|
|
||||||
{ commercial, &TNTGameInfo, pack_tnt }, // Doom2TNT
|
|
||||||
{ commercial, &PlutoniaGameInfo, pack_plut }, // Doom2Plutonia
|
|
||||||
{ commercial, &HexenGameInfo, doom2 }, // Hexen
|
|
||||||
{ commercial, &HexenDKGameInfo, doom2 }, // HexenDK
|
|
||||||
{ commercial, &HexenGameInfo, doom2 }, // Hexen Demo
|
|
||||||
{ commercial, &CommercialGameInfo, doom2 }, // Doom2
|
|
||||||
{ shareware, &HereticSWGameInfo, doom }, // HereticShareware
|
|
||||||
{ retail, &HereticGameInfo, doom }, // HereticExtended
|
|
||||||
{ retail, &HereticGameInfo, doom }, // Heretic
|
|
||||||
{ shareware, &SharewareGameInfo, doom }, // DoomShareware
|
|
||||||
{ retail, &RetailGameInfo, doom }, // UltimateDoom
|
|
||||||
{ registered, &RegisteredGameInfo, doom }, // DoomRegistered
|
|
||||||
{ commercial, &StrifeGameInfo, doom2 }, // Strife
|
|
||||||
{ commercial, &StrifeTeaserGameInfo, doom2 }, // StrifeTeaser
|
|
||||||
{ commercial, &StrifeTeaser2GameInfo, doom2 }, // StrifeTeaser2
|
|
||||||
{ commercial, &CommercialGameInfo, doom2 }, // FreeDoom
|
|
||||||
{ shareware, &SharewareGameInfo, doom }, // FreeDoom1
|
|
||||||
{ commercial, &CommercialGameInfo, doom2 }, // FreeDM
|
|
||||||
{ registered, &ChexGameInfo, doom }, // Chex Quest
|
|
||||||
{ registered, &Chex3GameInfo, doom }, // Chex Quest 3
|
|
||||||
};
|
|
||||||
|
|
||||||
D_AddFile (iwadpath);
|
|
||||||
|
|
||||||
if ((unsigned)type < NUM_IWAD_TYPES)
|
|
||||||
{
|
|
||||||
gamemode = Datas[type].Mode;
|
|
||||||
gameinfo = *Datas[type].Info;
|
|
||||||
gamemission = Datas[type].Mission;
|
|
||||||
if (type == IWAD_HereticExtended)
|
|
||||||
{
|
|
||||||
gameinfo.flags |= GI_MENUHACK_EXTENDED;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
gamemode = undetermined;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
//==========================================================================
|
|
||||||
//
|
|
||||||
// ScanIWAD
|
|
||||||
//
|
|
||||||
// Scan the contents of an IWAD to determine which one it is
|
|
||||||
//==========================================================================
|
|
||||||
|
|
||||||
static EIWADType ScanIWAD (const char *iwad)
|
|
||||||
{
|
|
||||||
static const char checklumps[][8] =
|
|
||||||
{
|
|
||||||
"E1M1",
|
|
||||||
"E4M2",
|
|
||||||
"MAP01",
|
|
||||||
"MAP40",
|
|
||||||
"MAP60",
|
|
||||||
"TITLE",
|
|
||||||
"REDTNT2",
|
|
||||||
"CAMO1",
|
|
||||||
{ 'E','X','T','E','N','D','E','D'},
|
|
||||||
"ENDSTRF",
|
|
||||||
"MAP33",
|
|
||||||
"INVCURS",
|
|
||||||
{ 'F','R','E','E','D','O','O','M' },
|
|
||||||
"W94_1",
|
|
||||||
{ 'P','O','S','S','H','0','M','0' },
|
|
||||||
"CYCLA1",
|
|
||||||
"FLMBA1",
|
|
||||||
"MAPINFO",
|
|
||||||
"E2M1","E2M2","E2M3","E2M4","E2M5","E2M6","E2M7","E2M8","E2M9",
|
|
||||||
"E3M1","E3M2","E3M3","E3M4","E3M5","E3M6","E3M7","E3M8","E3M9",
|
|
||||||
"DPHOOF","BFGGA0","HEADA1","CYBRA1",
|
|
||||||
{ 'S','P','I','D','A','1','D','1' },
|
|
||||||
|
|
||||||
};
|
|
||||||
#define NUM_CHECKLUMPS (sizeof(checklumps)/8)
|
|
||||||
enum
|
|
||||||
{
|
|
||||||
Check_e1m1,
|
|
||||||
Check_e4m1,
|
|
||||||
Check_map01,
|
|
||||||
Check_map40,
|
|
||||||
Check_map60,
|
|
||||||
Check_title,
|
|
||||||
Check_redtnt2,
|
|
||||||
Check_cam01,
|
|
||||||
Check_Extended,
|
|
||||||
Check_endstrf,
|
|
||||||
Check_map33,
|
|
||||||
Check_invcurs,
|
|
||||||
Check_FreeDoom,
|
|
||||||
Check_W94_1,
|
|
||||||
Check_POSSH0M0,
|
|
||||||
Check_Cycla1,
|
|
||||||
Check_Flmba1,
|
|
||||||
Check_Mapinfo,
|
|
||||||
Check_e2m1
|
|
||||||
};
|
|
||||||
int lumpsfound[NUM_CHECKLUMPS];
|
|
||||||
size_t i;
|
|
||||||
wadinfo_t header;
|
|
||||||
FILE *f;
|
|
||||||
|
|
||||||
memset (lumpsfound, 0, sizeof(lumpsfound));
|
|
||||||
if ( (f = fopen (iwad, "rb")) )
|
|
||||||
{
|
|
||||||
fread (&header, sizeof(header), 1, f);
|
|
||||||
if (header.Magic == IWAD_ID || header.Magic == PWAD_ID)
|
|
||||||
{
|
|
||||||
header.NumLumps = LittleLong(header.NumLumps);
|
|
||||||
if (0 == fseek (f, LittleLong(header.InfoTableOfs), SEEK_SET))
|
|
||||||
{
|
|
||||||
for (i = 0; i < (size_t)header.NumLumps; i++)
|
|
||||||
{
|
|
||||||
wadlump_t lump;
|
|
||||||
size_t j;
|
|
||||||
|
|
||||||
if (0 == fread (&lump, sizeof(lump), 1, f))
|
|
||||||
break;
|
|
||||||
for (j = 0; j < NUM_CHECKLUMPS; j++)
|
|
||||||
if (strnicmp (lump.Name, checklumps[j], 8) == 0)
|
|
||||||
lumpsfound[j]++;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
fclose (f);
|
|
||||||
}
|
|
||||||
|
|
||||||
if (lumpsfound[Check_title] && lumpsfound[Check_map60])
|
|
||||||
{
|
|
||||||
return IWAD_HexenDK;
|
|
||||||
}
|
|
||||||
else if (lumpsfound[Check_map33] && lumpsfound[Check_endstrf])
|
|
||||||
{
|
|
||||||
if (lumpsfound[Check_map01])
|
|
||||||
{
|
|
||||||
return IWAD_Strife;
|
|
||||||
}
|
|
||||||
else if (lumpsfound[Check_invcurs])
|
|
||||||
{
|
|
||||||
return IWAD_StrifeTeaser2;
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
return IWAD_StrifeTeaser;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
else if (lumpsfound[Check_map01])
|
|
||||||
{
|
|
||||||
if (lumpsfound[Check_FreeDoom])
|
|
||||||
{
|
|
||||||
// Is there a 100% reliable way to tell FreeDoom and FreeDM
|
|
||||||
// apart based solely on the lump names?
|
|
||||||
if (strstr(iwad, "freedm.wad") || strstr(iwad, "FREEDM.WAD"))
|
|
||||||
{
|
|
||||||
return IWAD_FreeDM;
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
return IWAD_FreeDoom;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
else if (lumpsfound[Check_redtnt2])
|
|
||||||
{
|
|
||||||
return IWAD_Doom2TNT;
|
|
||||||
}
|
|
||||||
else if (lumpsfound[Check_cam01])
|
|
||||||
{
|
|
||||||
return IWAD_Doom2Plutonia;
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
if (lumpsfound[Check_title])
|
|
||||||
{
|
|
||||||
if (lumpsfound[Check_map40])
|
|
||||||
{
|
|
||||||
return IWAD_Hexen;
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
return IWAD_HexenDemo;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
return IWAD_Doom2;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
else if (lumpsfound[Check_e1m1])
|
|
||||||
{
|
|
||||||
if (lumpsfound[Check_title])
|
|
||||||
{
|
|
||||||
if (!lumpsfound[Check_e2m1])
|
|
||||||
{
|
|
||||||
return IWAD_HereticShareware;
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
if (lumpsfound[Check_Extended])
|
|
||||||
{
|
|
||||||
return IWAD_HereticExtended;
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
return IWAD_Heretic;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
else if (lumpsfound[Check_Cycla1] && lumpsfound[Check_Flmba1])
|
|
||||||
{
|
|
||||||
if (!lumpsfound[Check_Mapinfo])
|
|
||||||
{
|
|
||||||
// The original release won't work without its hacked custom EXE.
|
|
||||||
//I_FatalError("Found an incompatible version of Chex Quest 3");
|
|
||||||
return NUM_IWAD_TYPES; // Can't use it.
|
|
||||||
}
|
|
||||||
return IWAD_ChexQuest3;
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
if (lumpsfound[Check_FreeDoom])
|
|
||||||
{
|
|
||||||
return IWAD_FreeDoom1;
|
|
||||||
}
|
|
||||||
for (i = Check_e2m1; i < NUM_CHECKLUMPS; i++)
|
|
||||||
{
|
|
||||||
if (!lumpsfound[i])
|
|
||||||
{
|
|
||||||
return IWAD_DoomShareware;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
if (i == NUM_CHECKLUMPS)
|
|
||||||
{
|
|
||||||
if (lumpsfound[Check_e4m1])
|
|
||||||
{
|
|
||||||
if (lumpsfound[Check_W94_1] && lumpsfound[Check_POSSH0M0])
|
|
||||||
{
|
|
||||||
return IWAD_ChexQuest;
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
return IWAD_UltimateDoom;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
return IWAD_DoomRegistered;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
return NUM_IWAD_TYPES; // Don't know
|
|
||||||
}
|
|
||||||
|
|
||||||
//==========================================================================
|
|
||||||
//
|
|
||||||
// CheckIWAD
|
|
||||||
//
|
|
||||||
// Tries to find an IWAD from a set of known IWAD names, and checks the
|
|
||||||
// contents of each one found to determine which game it belongs to.
|
|
||||||
// Returns the number of new wads found in this pass (does not count wads
|
|
||||||
// found from a previous call).
|
|
||||||
//
|
|
||||||
//==========================================================================
|
|
||||||
|
|
||||||
static int CheckIWAD (const char *doomwaddir, WadStuff *wads)
|
|
||||||
{
|
|
||||||
const char *slash;
|
|
||||||
int i;
|
|
||||||
int numfound;
|
|
||||||
|
|
||||||
numfound = 0;
|
|
||||||
|
|
||||||
slash = (doomwaddir[0] && doomwaddir[strlen (doomwaddir)-1] != '/') ? "/" : "";
|
|
||||||
|
|
||||||
// Search for a pre-defined IWAD
|
|
||||||
for (i = IWADNames[0] ? 0 : 1; IWADNames[i]; i++)
|
|
||||||
{
|
|
||||||
if (wads[i].Path.IsEmpty())
|
|
||||||
{
|
|
||||||
FString iwad;
|
|
||||||
|
|
||||||
iwad.Format ("%s%s%s", doomwaddir, slash, IWADNames[i]);
|
|
||||||
FixPathSeperator (iwad.LockBuffer());
|
|
||||||
iwad.UnlockBuffer();
|
|
||||||
if (FileExists (iwad))
|
|
||||||
{
|
|
||||||
wads[i].Type = ScanIWAD (iwad);
|
|
||||||
if (wads[i].Type != NUM_IWAD_TYPES)
|
|
||||||
{
|
|
||||||
wads[i].Path = iwad;
|
|
||||||
numfound++;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
return numfound;
|
|
||||||
}
|
|
||||||
|
|
||||||
//==========================================================================
|
|
||||||
//
|
|
||||||
// CheckIWADinEnvDir
|
|
||||||
//
|
|
||||||
// Checks for an IWAD in a path that contains one or more environment
|
|
||||||
// variables.
|
|
||||||
//
|
|
||||||
//==========================================================================
|
|
||||||
|
|
||||||
static int CheckIWADinEnvDir (const char *str, WadStuff *wads)
|
|
||||||
{
|
|
||||||
FString expanded = ExpandEnvVars (str);
|
|
||||||
|
|
||||||
if (!expanded.IsEmpty())
|
|
||||||
{
|
|
||||||
char *dir = expanded.LockBuffer ();
|
|
||||||
FixPathSeperator (dir);
|
|
||||||
expanded.UnlockBuffer ();
|
|
||||||
if (expanded[expanded.Len() - 1] != '/')
|
|
||||||
{
|
|
||||||
expanded += '/';
|
|
||||||
}
|
|
||||||
return CheckIWAD (expanded, wads);
|
|
||||||
}
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
|
|
||||||
//==========================================================================
|
|
||||||
//
|
|
||||||
// IdentifyVersion
|
|
||||||
//
|
|
||||||
// Tries to find an IWAD in one of four directories under DOS or Win32:
|
|
||||||
// 1. Current directory
|
|
||||||
// 2. Executable directory
|
|
||||||
// 3. $DOOMWADDIR
|
|
||||||
// 4. $HOME
|
|
||||||
//
|
|
||||||
// Under UNIX OSes, the search path is:
|
|
||||||
// 1. Current directory
|
|
||||||
// 2. $DOOMWADDIR
|
|
||||||
// 3. $HOME/.zdoom
|
|
||||||
// 4. The share directory defined at compile time (/usr/local/share/zdoom)
|
|
||||||
//
|
|
||||||
// The search path can be altered by editing the IWADSearch.Directories
|
|
||||||
// section of the config file.
|
|
||||||
//
|
|
||||||
//==========================================================================
|
|
||||||
|
|
||||||
static EIWADType IdentifyVersion (const char *zdoom_wad)
|
|
||||||
{
|
|
||||||
WadStuff wads[countof(IWADNames)];
|
|
||||||
size_t foundwads[NUM_IWAD_TYPES] = { 0 };
|
|
||||||
const char *iwadparm = Args->CheckValue ("-iwad");
|
|
||||||
size_t numwads;
|
|
||||||
int pickwad;
|
|
||||||
size_t i;
|
|
||||||
bool iwadparmfound = false;
|
|
||||||
FString custwad;
|
|
||||||
|
|
||||||
if (iwadparm)
|
|
||||||
{
|
|
||||||
custwad = iwadparm;
|
|
||||||
FixPathSeperator (custwad.LockBuffer());
|
|
||||||
if (CheckIWAD (custwad, wads))
|
|
||||||
{ // -iwad parameter was a directory
|
|
||||||
iwadparm = NULL;
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
DefaultExtension (custwad, ".wad");
|
|
||||||
iwadparm = custwad;
|
|
||||||
IWADNames[0] = iwadparm;
|
|
||||||
CheckIWAD ("", wads);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
if (iwadparm == NULL || wads[0].Path.IsEmpty())
|
|
||||||
{
|
|
||||||
if (GameConfig->SetSection ("IWADSearch.Directories"))
|
|
||||||
{
|
|
||||||
const char *key;
|
|
||||||
const char *value;
|
|
||||||
|
|
||||||
while (GameConfig->NextInSection (key, value))
|
|
||||||
{
|
|
||||||
if (stricmp (key, "Path") == 0)
|
|
||||||
{
|
|
||||||
if (strchr (value, '$') != NULL)
|
|
||||||
{
|
|
||||||
CheckIWADinEnvDir (value, wads);
|
|
||||||
}
|
|
||||||
#ifdef unix
|
|
||||||
else if (*value == '~' && (*(value + 1) == 0 || *(value + 1) == '/'))
|
|
||||||
{
|
|
||||||
FString homepath = GetUserFile (*(value + 1) ? value + 2 : value + 1, true);
|
|
||||||
CheckIWAD (homepath, wads);
|
|
||||||
}
|
|
||||||
#endif
|
|
||||||
else
|
|
||||||
{
|
|
||||||
CheckIWAD (value, wads);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
#ifdef _WIN32
|
|
||||||
FString steam_path = I_GetSteamPath();
|
|
||||||
if (steam_path.IsNotEmpty())
|
|
||||||
{
|
|
||||||
static const char *const steam_dirs[] =
|
|
||||||
{
|
|
||||||
"doom 2/base",
|
|
||||||
"final doom/base",
|
|
||||||
"heretic shadow of the serpent riders/base",
|
|
||||||
"hexen/base",
|
|
||||||
"hexen deathkings of the dark citadel/base",
|
|
||||||
"ultimate doom/base"
|
|
||||||
};
|
|
||||||
steam_path += "/SteamApps/common/";
|
|
||||||
for (i = 0; i < countof(steam_dirs); ++i)
|
|
||||||
{
|
|
||||||
CheckIWAD (steam_path + steam_dirs[i], wads);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
#endif
|
|
||||||
}
|
|
||||||
|
|
||||||
if (iwadparm != NULL && !wads[0].Path.IsEmpty())
|
|
||||||
{
|
|
||||||
iwadparmfound = true;
|
|
||||||
}
|
|
||||||
|
|
||||||
for (i = numwads = 0; i < countof(IWADNames); i++)
|
|
||||||
{
|
|
||||||
if (!wads[i].Path.IsEmpty())
|
|
||||||
{
|
|
||||||
if (i != numwads)
|
|
||||||
{
|
|
||||||
wads[numwads] = wads[i];
|
|
||||||
}
|
|
||||||
foundwads[wads[numwads].Type] = numwads + 1;
|
|
||||||
numwads++;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
if (foundwads[IWAD_HexenDK] && !foundwads[IWAD_Hexen])
|
|
||||||
{ // Cannot play Hexen DK without Hexen
|
|
||||||
size_t kill = foundwads[IWAD_HexenDK];
|
|
||||||
for (i = kill; i < numwads; ++i)
|
|
||||||
{
|
|
||||||
wads[i - 1] = wads[i];
|
|
||||||
}
|
|
||||||
numwads--;
|
|
||||||
foundwads[IWAD_HexenDK] = 0;
|
|
||||||
for (i = 0; i < NUM_IWAD_TYPES; ++i)
|
|
||||||
{
|
|
||||||
if (foundwads[i] > kill)
|
|
||||||
{
|
|
||||||
foundwads[i]--;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
if (numwads == 0)
|
|
||||||
{
|
|
||||||
I_FatalError ("Cannot find a game IWAD (doom.wad, doom2.wad, heretic.wad, etc.).\n"
|
|
||||||
"Did you install ZDoom properly? You can do either of the following:\n"
|
|
||||||
"\n"
|
|
||||||
"1. Place one or more of these wads in the same directory as ZDoom.\n"
|
|
||||||
"2. Edit your zdoom-username.ini and add the directories of your iwads\n"
|
|
||||||
"to the list beneath [IWADSearch.Directories]");
|
|
||||||
}
|
|
||||||
|
|
||||||
pickwad = 0;
|
|
||||||
|
|
||||||
if (!iwadparmfound && numwads > 1)
|
|
||||||
{
|
|
||||||
int defiwad = 0;
|
|
||||||
|
|
||||||
// Locate the user's prefered IWAD, if it was found.
|
|
||||||
if (defaultiwad[0] != '\0')
|
|
||||||
{
|
|
||||||
for (i = 0; i < numwads; ++i)
|
|
||||||
{
|
|
||||||
FString basename = ExtractFileBase (wads[i].Path);
|
|
||||||
if (stricmp (basename, defaultiwad) == 0)
|
|
||||||
{
|
|
||||||
defiwad = (int)i;
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
pickwad = I_PickIWad (wads, (int)numwads, queryiwad, defiwad);
|
|
||||||
if (pickwad >= 0)
|
|
||||||
{
|
|
||||||
// The newly selected IWAD becomes the new default
|
|
||||||
FString basename = ExtractFileBase (wads[pickwad].Path);
|
|
||||||
defaultiwad = basename;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
if (pickwad < 0)
|
|
||||||
exit (0);
|
|
||||||
|
|
||||||
// zdoom.pk3 must always be the first file loaded and the IWAD second.
|
|
||||||
D_AddFile (zdoom_wad);
|
|
||||||
|
|
||||||
if (wads[pickwad].Type == IWAD_HexenDK)
|
|
||||||
{ // load hexen.wad before loading hexdd.wad
|
|
||||||
D_AddFile (wads[foundwads[IWAD_Hexen]-1].Path);
|
|
||||||
}
|
|
||||||
|
|
||||||
SetIWAD (wads[pickwad].Path, wads[pickwad].Type);
|
|
||||||
|
|
||||||
if (wads[pickwad].Type == IWAD_Strife)
|
|
||||||
{ // Try to load voices.wad along with strife1.wad
|
|
||||||
long lastslash = wads[pickwad].Path.LastIndexOf ('/');
|
|
||||||
FString path;
|
|
||||||
|
|
||||||
if (lastslash == -1)
|
|
||||||
{
|
|
||||||
path = "";// wads[pickwad].Path;
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
path = FString (wads[pickwad].Path.GetChars(), lastslash + 1);
|
|
||||||
}
|
|
||||||
path += "voices.wad";
|
|
||||||
D_AddFile (path);
|
|
||||||
}
|
|
||||||
|
|
||||||
return wads[pickwad].Type;
|
|
||||||
}
|
|
||||||
|
|
||||||
//==========================================================================
|
//==========================================================================
|
||||||
//
|
//
|
||||||
|
@ -2195,7 +1553,6 @@ void D_DoomMain (void)
|
||||||
char *v;
|
char *v;
|
||||||
const char *wad;
|
const char *wad;
|
||||||
DArgs *execFiles;
|
DArgs *execFiles;
|
||||||
const IWADInfo *iwad_info;
|
|
||||||
|
|
||||||
srand(I_MSTime());
|
srand(I_MSTime());
|
||||||
|
|
||||||
|
@ -2241,13 +1598,11 @@ void D_DoomMain (void)
|
||||||
|
|
||||||
// Load zdoom.pk3 alone so that we can get access to the internal gameinfos before
|
// Load zdoom.pk3 alone so that we can get access to the internal gameinfos before
|
||||||
// the IWAD is known.
|
// the IWAD is known.
|
||||||
wadlist_t *basewad = (wadlist_t*)M_Malloc(sizeof(wadlist_t) + strlen(wad));
|
|
||||||
strcpy(basewad->name, wad);
|
|
||||||
basewad->next = NULL;
|
|
||||||
Wads.InitMultipleFiles(&basewad);
|
|
||||||
|
|
||||||
iwad_info = &IWADInfos[IdentifyVersion(wad)];
|
const IWADInfo *iwad_info = D_FindIWAD(wad);
|
||||||
I_SetIWADInfo(iwad_info);
|
gameinfo.gametype = iwad_info->gametype;
|
||||||
|
gameinfo.flags = iwad_info->flags;
|
||||||
|
|
||||||
GameConfig->DoGameSetup (GameNames[gameinfo.gametype]);
|
GameConfig->DoGameSetup (GameNames[gameinfo.gametype]);
|
||||||
|
|
||||||
if (!(gameinfo.flags & GI_SHAREWARE))
|
if (!(gameinfo.flags & GI_SHAREWARE))
|
||||||
|
@ -2515,7 +1870,7 @@ void D_DoomMain (void)
|
||||||
|
|
||||||
// [RH] Parse through all loaded mapinfo lumps
|
// [RH] Parse through all loaded mapinfo lumps
|
||||||
Printf ("G_ParseMapInfo: Load map definitions.\n");
|
Printf ("G_ParseMapInfo: Load map definitions.\n");
|
||||||
G_ParseMapInfo ();
|
G_ParseMapInfo (iwad_info->MapInfo);
|
||||||
|
|
||||||
// [RH] Parse any SNDINFO lumps
|
// [RH] Parse any SNDINFO lumps
|
||||||
Printf ("S_InitData: Load sound definitions.\n");
|
Printf ("S_InitData: Load sound definitions.\n");
|
||||||
|
|
|
@ -26,6 +26,7 @@
|
||||||
#define __D_MAIN__
|
#define __D_MAIN__
|
||||||
|
|
||||||
#include "doomtype.h"
|
#include "doomtype.h"
|
||||||
|
#include "gametype.h"
|
||||||
|
|
||||||
struct event_t;
|
struct event_t;
|
||||||
|
|
||||||
|
@ -50,6 +51,7 @@ void D_PageTicker (void);
|
||||||
void D_PageDrawer (void);
|
void D_PageDrawer (void);
|
||||||
void D_AdvanceDemo (void);
|
void D_AdvanceDemo (void);
|
||||||
void D_StartTitle (void);
|
void D_StartTitle (void);
|
||||||
|
void D_AddFile (const char *file);
|
||||||
|
|
||||||
|
|
||||||
// [RH] Set this to something to draw an icon during the next screen refresh.
|
// [RH] Set this to something to draw an icon during the next screen refresh.
|
||||||
|
@ -78,6 +80,7 @@ enum EIWADType
|
||||||
IWAD_FreeDM,
|
IWAD_FreeDM,
|
||||||
IWAD_ChexQuest,
|
IWAD_ChexQuest,
|
||||||
IWAD_ChexQuest3,
|
IWAD_ChexQuest3,
|
||||||
|
IWAD_Custom,
|
||||||
|
|
||||||
NUM_IWAD_TYPES
|
NUM_IWAD_TYPES
|
||||||
};
|
};
|
||||||
|
@ -96,6 +99,9 @@ struct IWADInfo
|
||||||
const char *Autoname; // Name of autoload ini section for this IWAD
|
const char *Autoname; // Name of autoload ini section for this IWAD
|
||||||
DWORD FgColor; // Foreground color for title banner
|
DWORD FgColor; // Foreground color for title banner
|
||||||
DWORD BkColor; // Background color for title banner
|
DWORD BkColor; // Background color for title banner
|
||||||
|
EGameType gametype; // which game are we playing?
|
||||||
|
const char *MapInfo; // Base mapinfo to load
|
||||||
|
int flags;
|
||||||
};
|
};
|
||||||
|
|
||||||
extern const IWADInfo IWADInfos[NUM_IWAD_TYPES];
|
extern const IWADInfo IWADInfos[NUM_IWAD_TYPES];
|
||||||
|
|
|
@ -44,18 +44,6 @@ typedef enum
|
||||||
} GameMode_t;
|
} GameMode_t;
|
||||||
|
|
||||||
|
|
||||||
// Mission packs - might be useful for TC stuff?
|
|
||||||
typedef enum
|
|
||||||
{
|
|
||||||
doom, // DOOM 1
|
|
||||||
doom2, // DOOM 2
|
|
||||||
pack_tnt, // TNT mission pack
|
|
||||||
pack_plut, // Plutonia pack
|
|
||||||
none
|
|
||||||
|
|
||||||
} GameMission_t;
|
|
||||||
|
|
||||||
|
|
||||||
// If rangecheck is undefined, most parameter validation debugging code
|
// If rangecheck is undefined, most parameter validation debugging code
|
||||||
// will not be compiled
|
// will not be compiled
|
||||||
#ifndef NORANGECHECKING
|
#ifndef NORANGECHECKING
|
||||||
|
|
|
@ -38,10 +38,6 @@ FStringTable GStrings;
|
||||||
// Game speed
|
// Game speed
|
||||||
EGameSpeed GameSpeed = SPEED_Normal;
|
EGameSpeed GameSpeed = SPEED_Normal;
|
||||||
|
|
||||||
// Game Mode - identify IWAD as shareware, retail etc.
|
|
||||||
int gamemode = undetermined;
|
|
||||||
int gamemission = doom;
|
|
||||||
|
|
||||||
// Show developer messages if true.
|
// Show developer messages if true.
|
||||||
CVAR (Bool, developer, false, 0)
|
CVAR (Bool, developer, false, 0)
|
||||||
|
|
||||||
|
|
|
@ -51,9 +51,6 @@ extern bool devparm; // DEBUG: launched with -devparm
|
||||||
// -----------------------------------------------------
|
// -----------------------------------------------------
|
||||||
// Game Mode - identify IWAD as shareware, retail etc.
|
// Game Mode - identify IWAD as shareware, retail etc.
|
||||||
//
|
//
|
||||||
extern int gamemode;
|
|
||||||
extern int gamemission;
|
|
||||||
|
|
||||||
// -------------------------------------------
|
// -------------------------------------------
|
||||||
// Selected skill type, map etc.
|
// Selected skill type, map etc.
|
||||||
//
|
//
|
||||||
|
|
|
@ -89,7 +89,7 @@ void F_AdvanceSlideshow ();
|
||||||
void F_StartFinale (const char *music, int musicorder, int cdtrack, unsigned int cdid, const char *flat,
|
void F_StartFinale (const char *music, int musicorder, int cdtrack, unsigned int cdid, const char *flat,
|
||||||
const char *text, INTBOOL textInLump, INTBOOL finalePic, INTBOOL lookupText, bool ending)
|
const char *text, INTBOOL textInLump, INTBOOL finalePic, INTBOOL lookupText, bool ending)
|
||||||
{
|
{
|
||||||
bool loopmusic = ending ? !(gameinfo.flags & GI_NOLOOPFINALEMUSIC) : true;
|
bool loopmusic = ending ? !gameinfo.noloopfinalemusic : true;
|
||||||
gameaction = ga_nothing;
|
gameaction = ga_nothing;
|
||||||
gamestate = GS_FINALE;
|
gamestate = GS_FINALE;
|
||||||
viewactive = false;
|
viewactive = false;
|
||||||
|
@ -229,7 +229,7 @@ void F_Ticker ()
|
||||||
if (FinaleStage == 0)
|
if (FinaleStage == 0)
|
||||||
{
|
{
|
||||||
if (interrupt ||
|
if (interrupt ||
|
||||||
((gamemode != commercial || gameinfo.flags & GI_SHAREWARE)
|
((!(gameinfo.flags & GI_MAPxx) || gameinfo.flags & GI_SHAREWARE)
|
||||||
&& FinaleCount > FinaleTextLen*TEXTSPEED+TEXTWAIT))
|
&& FinaleCount > FinaleTextLen*TEXTSPEED+TEXTWAIT))
|
||||||
{
|
{
|
||||||
if (FinaleCount < FinaleTextLen*TEXTSPEED+10)
|
if (FinaleCount < FinaleTextLen*TEXTSPEED+10)
|
||||||
|
@ -308,7 +308,7 @@ void F_Ticker ()
|
||||||
case 12: // Pic 2, Text 2
|
case 12: // Pic 2, Text 2
|
||||||
GetFinaleText ("win2msg");
|
GetFinaleText ("win2msg");
|
||||||
FinaleEndCount = FinaleTextLen*TEXTSPEED+TEXTWAIT;
|
FinaleEndCount = FinaleTextLen*TEXTSPEED+TEXTWAIT;
|
||||||
S_ChangeMusic ("orb", 0, !(gameinfo.flags & GI_NOLOOPFINALEMUSIC));
|
S_ChangeMusic ("orb", 0, !gameinfo.noloopfinalemusic);
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case 13: // Pic 2 -- Fade out
|
case 13: // Pic 2 -- Fade out
|
||||||
|
@ -319,7 +319,7 @@ void F_Ticker ()
|
||||||
case 14: // Pic 3 -- Fade in
|
case 14: // Pic 3 -- Fade in
|
||||||
FinaleEndCount = 71;
|
FinaleEndCount = 71;
|
||||||
FadeDir = -1;
|
FadeDir = -1;
|
||||||
S_ChangeMusic ("chess", 0, !(gameinfo.flags & GI_NOLOOPFINALEMUSIC));
|
S_ChangeMusic ("chess", 0, !gameinfo.noloopfinalemusic);
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case 15: // Pic 3, Text 3
|
case 15: // Pic 3, Text 3
|
||||||
|
@ -1247,19 +1247,19 @@ void F_Drawer (void)
|
||||||
{
|
{
|
||||||
default:
|
default:
|
||||||
case END_Pic1:
|
case END_Pic1:
|
||||||
picname = gameinfo.finalePage1;
|
picname = gameinfo.GetFinalePage(1);
|
||||||
screen->DrawTexture (TexMan[picname], 0, 0,
|
screen->DrawTexture (TexMan[picname], 0, 0,
|
||||||
DTA_DestWidth, screen->GetWidth(),
|
DTA_DestWidth, screen->GetWidth(),
|
||||||
DTA_DestHeight, screen->GetHeight(), TAG_DONE);
|
DTA_DestHeight, screen->GetHeight(), TAG_DONE);
|
||||||
break;
|
break;
|
||||||
case END_Pic2:
|
case END_Pic2:
|
||||||
picname = gameinfo.finalePage2;
|
picname = gameinfo.GetFinalePage(2);
|
||||||
screen->DrawTexture (TexMan[picname], 0, 0,
|
screen->DrawTexture (TexMan[picname], 0, 0,
|
||||||
DTA_DestWidth, screen->GetWidth(),
|
DTA_DestWidth, screen->GetWidth(),
|
||||||
DTA_DestHeight, screen->GetHeight(), TAG_DONE);
|
DTA_DestHeight, screen->GetHeight(), TAG_DONE);
|
||||||
break;
|
break;
|
||||||
case END_Pic3:
|
case END_Pic3:
|
||||||
picname = gameinfo.finalePage3;
|
picname = gameinfo.GetFinalePage(3);
|
||||||
screen->DrawTexture (TexMan[picname], 0, 0,
|
screen->DrawTexture (TexMan[picname], 0, 0,
|
||||||
DTA_DestWidth, screen->GetWidth(),
|
DTA_DestWidth, screen->GetWidth(),
|
||||||
DTA_DestHeight, screen->GetHeight(), TAG_DONE);
|
DTA_DestHeight, screen->GetHeight(), TAG_DONE);
|
||||||
|
|
|
@ -189,7 +189,7 @@ void G_SetForEndGame (char *nextmap)
|
||||||
{
|
{
|
||||||
SetEndSequence (nextmap, END_Chess);
|
SetEndSequence (nextmap, END_Chess);
|
||||||
}
|
}
|
||||||
else if (gamemode == commercial)
|
else if (gameinfo.gametype == GAME_Doom && (gameinfo.flags & GI_MAPxx))
|
||||||
{
|
{
|
||||||
SetEndSequence (nextmap, END_Cast);
|
SetEndSequence (nextmap, END_Cast);
|
||||||
}
|
}
|
||||||
|
|
|
@ -82,9 +82,10 @@ struct FMapInfoParser
|
||||||
void ParseNextMap(char *mapname);
|
void ParseNextMap(char *mapname);
|
||||||
level_info_t *ParseMapHeader(level_info_t &defaultinfo);
|
level_info_t *ParseMapHeader(level_info_t &defaultinfo);
|
||||||
void ParseMapDefinition(level_info_t &leveldef);
|
void ParseMapDefinition(level_info_t &leveldef);
|
||||||
|
void ParseGameInfo();
|
||||||
void ParseEpisodeInfo ();
|
void ParseEpisodeInfo ();
|
||||||
void ParseSkill ();
|
void ParseSkill ();
|
||||||
void ParseMapInfo (int lump, level_info_t &gamedefaults);
|
void ParseMapInfo (int lump, level_info_t &gamedefaults, level_info_t &defaultinfo);
|
||||||
|
|
||||||
void ParseOpenBrace();
|
void ParseOpenBrace();
|
||||||
bool ParseCloseBrace();
|
bool ParseCloseBrace();
|
||||||
|
@ -500,7 +501,7 @@ level_info_t *CheckLevelRedirect (level_info_t *info);
|
||||||
|
|
||||||
FString CalcMapName (int episode, int level);
|
FString CalcMapName (int episode, int level);
|
||||||
|
|
||||||
void G_ParseMapInfo (void);
|
void G_ParseMapInfo (const char *basemapinfo);
|
||||||
|
|
||||||
void G_ClearSnapshots (void);
|
void G_ClearSnapshots (void);
|
||||||
void P_RemoveDefereds ();
|
void P_RemoveDefereds ();
|
||||||
|
|
|
@ -1763,10 +1763,8 @@ static void SetLevelNum (level_info_t *info, int num)
|
||||||
//
|
//
|
||||||
//==========================================================================
|
//==========================================================================
|
||||||
|
|
||||||
void FMapInfoParser::ParseMapInfo (int lump, level_info_t &gamedefaults)
|
void FMapInfoParser::ParseMapInfo (int lump, level_info_t &gamedefaults, level_info_t &defaultinfo)
|
||||||
{
|
{
|
||||||
level_info_t defaultinfo;
|
|
||||||
|
|
||||||
sc.OpenLumpNum(lump);
|
sc.OpenLumpNum(lump);
|
||||||
|
|
||||||
defaultinfo = gamedefaults;
|
defaultinfo = gamedefaults;
|
||||||
|
@ -1774,7 +1772,19 @@ void FMapInfoParser::ParseMapInfo (int lump, level_info_t &gamedefaults)
|
||||||
|
|
||||||
while (sc.GetString ())
|
while (sc.GetString ())
|
||||||
{
|
{
|
||||||
if (sc.Compare("gamedefaults"))
|
if (sc.Compare("include"))
|
||||||
|
{
|
||||||
|
sc.MustGetString();
|
||||||
|
int inclump = Wads.CheckNumForFullName(sc.String, true);
|
||||||
|
if (inclump < 0)
|
||||||
|
{
|
||||||
|
sc.ScriptError("include file '%s' not found", sc.String);
|
||||||
|
}
|
||||||
|
FScanner saved_sc = sc;
|
||||||
|
ParseMapInfo(inclump, gamedefaults, defaultinfo);
|
||||||
|
sc = saved_sc;
|
||||||
|
}
|
||||||
|
else if (sc.Compare("gamedefaults"))
|
||||||
{
|
{
|
||||||
gamedefaults.Reset();
|
gamedefaults.Reset();
|
||||||
ParseMapDefinition(gamedefaults);
|
ParseMapDefinition(gamedefaults);
|
||||||
|
@ -1825,6 +1835,18 @@ void FMapInfoParser::ParseMapInfo (int lump, level_info_t &gamedefaults)
|
||||||
{
|
{
|
||||||
AllSkills.Clear();
|
AllSkills.Clear();
|
||||||
}
|
}
|
||||||
|
else if (sc.Compare("gameinfo"))
|
||||||
|
{
|
||||||
|
if (format_type != FMT_Old)
|
||||||
|
{
|
||||||
|
format_type = FMT_New;
|
||||||
|
ParseGameInfo();
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
sc.ScriptError("gameinfo definitions not supported with old MAPINFO syntax");
|
||||||
|
}
|
||||||
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
sc.ScriptError("%s: Unknown top level keyword", sc.String);
|
sc.ScriptError("%s: Unknown top level keyword", sc.String);
|
||||||
|
@ -1841,7 +1863,7 @@ void FMapInfoParser::ParseMapInfo (int lump, level_info_t &gamedefaults)
|
||||||
//
|
//
|
||||||
//==========================================================================
|
//==========================================================================
|
||||||
|
|
||||||
void G_ParseMapInfo ()
|
void G_ParseMapInfo (const char *basemapinfo)
|
||||||
{
|
{
|
||||||
int lump, lastlump = 0;
|
int lump, lastlump = 0;
|
||||||
level_info_t gamedefaults;
|
level_info_t gamedefaults;
|
||||||
|
@ -1849,20 +1871,19 @@ void G_ParseMapInfo ()
|
||||||
atterm(ClearEpisodes);
|
atterm(ClearEpisodes);
|
||||||
|
|
||||||
// Parse the default MAPINFO for the current game.
|
// Parse the default MAPINFO for the current game.
|
||||||
for(int i=0; i<2; i++)
|
if (basemapinfo != NULL)
|
||||||
{
|
{
|
||||||
if (gameinfo.mapinfo[i] != NULL)
|
FMapInfoParser parse;
|
||||||
{
|
level_info_t defaultinfo;
|
||||||
FMapInfoParser parse;
|
parse.ParseMapInfo(Wads.GetNumForFullName(basemapinfo), gamedefaults, defaultinfo);
|
||||||
parse.ParseMapInfo(Wads.GetNumForFullName(gameinfo.mapinfo[i]), gamedefaults);
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// Parse any extra MAPINFOs.
|
// Parse any extra MAPINFOs.
|
||||||
while ((lump = Wads.FindLump ("MAPINFO", &lastlump)) != -1)
|
while ((lump = Wads.FindLump ("MAPINFO", &lastlump)) != -1)
|
||||||
{
|
{
|
||||||
FMapInfoParser parse;
|
FMapInfoParser parse;
|
||||||
parse.ParseMapInfo(lump, gamedefaults);
|
level_info_t defaultinfo;
|
||||||
|
parse.ParseMapInfo(lump, gamedefaults, defaultinfo);
|
||||||
}
|
}
|
||||||
EndSequences.ShrinkToFit ();
|
EndSequences.ShrinkToFit ();
|
||||||
|
|
||||||
|
|
663
src/gi.cpp
663
src/gi.cpp
|
@ -37,6 +37,11 @@
|
||||||
#include "gi.h"
|
#include "gi.h"
|
||||||
#include "m_fixed.h"
|
#include "m_fixed.h"
|
||||||
#include "v_palette.h"
|
#include "v_palette.h"
|
||||||
|
#include "sc_man.h"
|
||||||
|
#include "w_wad.h"
|
||||||
|
#include "i_system.h"
|
||||||
|
#include "v_video.h"
|
||||||
|
#include "g_level.h"
|
||||||
|
|
||||||
gameinfo_t gameinfo;
|
gameinfo_t gameinfo;
|
||||||
|
|
||||||
|
@ -70,512 +75,184 @@ static gameborder_t StrifeBorder =
|
||||||
"brdr_bl", "brdr_b", "brdr_br"
|
"brdr_bl", "brdr_b", "brdr_br"
|
||||||
};
|
};
|
||||||
|
|
||||||
gameinfo_t HexenGameInfo =
|
// Custom GAMEINFO ------------------------------------------------------------
|
||||||
|
|
||||||
|
const char* GameInfoBoarders[] =
|
||||||
{
|
{
|
||||||
GI_PAGESARERAW | GI_MAPxx | GI_NOLOOPFINALEMUSIC | GI_INFOINDEXED | GI_ALWAYSFALLINGDAMAGE,
|
"DoomBorder",
|
||||||
"TITLE",
|
"HereticBorder",
|
||||||
"CREDIT",
|
"StrifeBorder",
|
||||||
"CREDIT",
|
NULL
|
||||||
"HEXEN",
|
|
||||||
280/35,
|
|
||||||
210/35,
|
|
||||||
200/35,
|
|
||||||
"Chat",
|
|
||||||
"hub",
|
|
||||||
"-NOFLAT",
|
|
||||||
"CREDIT",
|
|
||||||
"CREDIT",
|
|
||||||
"CREDIT",
|
|
||||||
{ { "TITLE", {4} } },
|
|
||||||
NULL,
|
|
||||||
33,
|
|
||||||
"F_022",
|
|
||||||
&HereticBorder,
|
|
||||||
32*FRACUNIT,
|
|
||||||
GAME_Hexen,
|
|
||||||
150,
|
|
||||||
"F_SKY",
|
|
||||||
24*FRACUNIT,
|
|
||||||
"xlat/heretic.txt", // not really correct but this was used before.
|
|
||||||
{ "mapinfo/hexen.txt", NULL },
|
|
||||||
MAKERGB(104,0,0),
|
|
||||||
MAKERGB(255,0,0),
|
|
||||||
"BagOfHolding", // Hexen doesn't have a backpack so use Heretic's.
|
|
||||||
NULL,
|
|
||||||
};
|
};
|
||||||
|
|
||||||
gameinfo_t HexenDKGameInfo =
|
#define GAMEINFOKEY_CSTRING(key, variable, length) \
|
||||||
{
|
else if(nextKey.CompareNoCase(variable) == 0) \
|
||||||
GI_PAGESARERAW | GI_MAPxx | GI_NOLOOPFINALEMUSIC | GI_INFOINDEXED | GI_ALWAYSFALLINGDAMAGE,
|
{ \
|
||||||
"TITLE",
|
sc.MustGetToken(TK_StringConst); \
|
||||||
"CREDIT",
|
if(strlen(sc.String) > length) \
|
||||||
"CREDIT",
|
{ \
|
||||||
"HEXEN",
|
sc.ScriptError("Value for '%s' can not be longer than %d characters.", #key, length); \
|
||||||
280/35,
|
} \
|
||||||
210/35,
|
strcpy(gameinfo.key, sc.String); \
|
||||||
200/35,
|
}
|
||||||
"Chat",
|
|
||||||
"hub",
|
|
||||||
"-NOFLAT-",
|
|
||||||
"CREDIT",
|
|
||||||
"CREDIT",
|
|
||||||
"CREDIT",
|
|
||||||
{ { "TITLE", {4} } },
|
|
||||||
NULL,
|
|
||||||
33,
|
|
||||||
"F_022",
|
|
||||||
&HereticBorder,
|
|
||||||
32*FRACUNIT,
|
|
||||||
GAME_Hexen,
|
|
||||||
150,
|
|
||||||
"F_SKY",
|
|
||||||
24*FRACUNIT,
|
|
||||||
"xlat/heretic.txt", // not really correct but this was used before.
|
|
||||||
{ "mapinfo/hexen.txt", NULL },
|
|
||||||
MAKERGB(104,0,0),
|
|
||||||
MAKERGB(255,0,0),
|
|
||||||
"BagOfHolding",
|
|
||||||
NULL,
|
|
||||||
};
|
|
||||||
|
|
||||||
gameinfo_t HereticGameInfo =
|
#define GAMEINFOKEY_STRINGARRAY(key, variable, length) \
|
||||||
{
|
else if(nextKey.CompareNoCase(variable) == 0) \
|
||||||
GI_PAGESARERAW | GI_INFOINDEXED,
|
{ \
|
||||||
"TITLE",
|
gameinfo.key.Clear(); \
|
||||||
"CREDIT",
|
do \
|
||||||
"CREDIT",
|
{ \
|
||||||
"MUS_TITL",
|
sc.MustGetToken(TK_StringConst); \
|
||||||
280/35,
|
if(strlen(sc.String) > length) \
|
||||||
210/35,
|
{ \
|
||||||
200/35,
|
sc.ScriptError("Value for '%s' can not be longer than %d characters.", #key, length); \
|
||||||
"misc/chat",
|
} \
|
||||||
"MUS_CPTD",
|
FName val = sc.String; \
|
||||||
"FLOOR25",
|
gameinfo.key.Push(val); \
|
||||||
"CREDIT",
|
} \
|
||||||
"CREDIT",
|
while (sc.CheckToken(',')); \
|
||||||
"CREDIT",
|
}
|
||||||
{ { "TITLE", {4} } },
|
|
||||||
NULL,
|
|
||||||
17,
|
|
||||||
"FLAT513",
|
|
||||||
&HereticBorder,
|
|
||||||
32*FRACUNIT,
|
|
||||||
GAME_Heretic,
|
|
||||||
150,
|
|
||||||
"F_SKY1",
|
|
||||||
24*FRACUNIT,
|
|
||||||
"xlat/heretic.txt",
|
|
||||||
{ "mapinfo/heretic.txt", NULL },
|
|
||||||
MAKERGB(104,0,0),
|
|
||||||
MAKERGB(255,0,0),
|
|
||||||
"BagOfHolding",
|
|
||||||
NULL,
|
|
||||||
};
|
|
||||||
|
|
||||||
gameinfo_t HereticSWGameInfo =
|
#define GAMEINFOKEY_STRING(key, variable) \
|
||||||
{
|
else if(nextKey.CompareNoCase(variable) == 0) \
|
||||||
GI_PAGESARERAW | GI_SHAREWARE | GI_INFOINDEXED,
|
{ \
|
||||||
"TITLE",
|
sc.MustGetToken(TK_StringConst); \
|
||||||
"CREDIT",
|
gameinfo.key = sc.String; \
|
||||||
"ORDER",
|
}
|
||||||
"MUS_TITL",
|
|
||||||
280/35,
|
|
||||||
210/35,
|
|
||||||
200/35,
|
|
||||||
"misc/chat",
|
|
||||||
"MUS_CPTD",
|
|
||||||
"FLOOR25",
|
|
||||||
"ORDER",
|
|
||||||
"CREDIT",
|
|
||||||
"CREDIT",
|
|
||||||
{ { "TITLE", {5} } },
|
|
||||||
NULL,
|
|
||||||
17,
|
|
||||||
"FLOOR04",
|
|
||||||
&HereticBorder,
|
|
||||||
32*FRACUNIT,
|
|
||||||
GAME_Heretic,
|
|
||||||
150,
|
|
||||||
"F_SKY1",
|
|
||||||
24*FRACUNIT,
|
|
||||||
"xlat/heretic.txt",
|
|
||||||
{ "mapinfo/heretic.txt", NULL },
|
|
||||||
MAKERGB(104,0,0),
|
|
||||||
MAKERGB(255,0,0),
|
|
||||||
"BagOfHolding",
|
|
||||||
NULL,
|
|
||||||
};
|
|
||||||
|
|
||||||
gameinfo_t SharewareGameInfo =
|
#define GAMEINFOKEY_INT(key, variable) \
|
||||||
{
|
else if(nextKey.CompareNoCase(variable) == 0) \
|
||||||
GI_SHAREWARE,
|
{ \
|
||||||
"TITLEPIC",
|
sc.MustGetNumber(); \
|
||||||
"CREDIT",
|
gameinfo.key = sc.Number; \
|
||||||
"HELP2",
|
}
|
||||||
"$MUSIC_INTRO",
|
|
||||||
5,
|
|
||||||
0,
|
|
||||||
200/35,
|
|
||||||
"misc/chat2",
|
|
||||||
"$MUSIC_VICTOR",
|
|
||||||
"FLOOR4_8",
|
|
||||||
"HELP2",
|
|
||||||
"VICTORY2",
|
|
||||||
"HELP2",
|
|
||||||
{ { "HELP1", "HELP2" } },
|
|
||||||
"menu/quit1",
|
|
||||||
1,
|
|
||||||
"FLOOR7_2",
|
|
||||||
&DoomBorder,
|
|
||||||
0,
|
|
||||||
GAME_Doom,
|
|
||||||
100,
|
|
||||||
"F_SKY1",
|
|
||||||
24*FRACUNIT,
|
|
||||||
"xlat/doom.txt",
|
|
||||||
{ "mapinfo/doomcommon.txt", "mapinfo/doom1.txt" },
|
|
||||||
MAKERGB(104,0,0),
|
|
||||||
MAKERGB(255,0,0),
|
|
||||||
"Backpack",
|
|
||||||
"sbarinfo/doom.txt",
|
|
||||||
};
|
|
||||||
|
|
||||||
gameinfo_t RegisteredGameInfo =
|
#define GAMEINFOKEY_FLOAT(key, variable) \
|
||||||
{
|
else if(nextKey.CompareNoCase(variable) == 0) \
|
||||||
0,
|
{ \
|
||||||
"TITLEPIC",
|
sc.MustGetFloat(); \
|
||||||
"CREDIT",
|
gameinfo.key = static_cast<float> (sc.Float); \
|
||||||
"HELP2",
|
}
|
||||||
"$MUSIC_INTRO",
|
|
||||||
5,
|
|
||||||
0,
|
|
||||||
200/35,
|
|
||||||
"misc/chat2",
|
|
||||||
"$MUSIC_VICTOR",
|
|
||||||
"FLOOR4_8",
|
|
||||||
"HELP2",
|
|
||||||
"VICTORY2",
|
|
||||||
"ENDPIC",
|
|
||||||
{ { "HELP1", "HELP2" } },
|
|
||||||
"menu/quit1",
|
|
||||||
2,
|
|
||||||
"FLOOR7_2",
|
|
||||||
&DoomBorder,
|
|
||||||
0,
|
|
||||||
GAME_Doom,
|
|
||||||
100,
|
|
||||||
"F_SKY1",
|
|
||||||
24*FRACUNIT,
|
|
||||||
"xlat/doom.txt",
|
|
||||||
{ "mapinfo/doomcommon.txt", "mapinfo/doom1.txt" },
|
|
||||||
MAKERGB(104,0,0),
|
|
||||||
MAKERGB(255,0,0),
|
|
||||||
"Backpack",
|
|
||||||
"sbarinfo/doom.txt",
|
|
||||||
};
|
|
||||||
|
|
||||||
gameinfo_t ChexGameInfo =
|
#define GAMEINFOKEY_FIXED(key, variable) \
|
||||||
{
|
else if(nextKey.CompareNoCase(variable) == 0) \
|
||||||
GI_CHEX_QUEST,
|
{ \
|
||||||
"TITLEPIC",
|
sc.MustGetFloat(); \
|
||||||
"CREDIT",
|
gameinfo.key = static_cast<int> (sc.Float*FRACUNIT); \
|
||||||
"HELP1",
|
}
|
||||||
"$MUSIC_INTRO",
|
|
||||||
5,
|
|
||||||
0,
|
|
||||||
200/35,
|
|
||||||
"misc/chat2",
|
|
||||||
"$MUSIC_VICTOR",
|
|
||||||
"FLOOR4_8",
|
|
||||||
"HELP2",
|
|
||||||
"VICTORY2",
|
|
||||||
"ENDPIC",
|
|
||||||
{ { "HELP1", "CREDIT" } },
|
|
||||||
"menu/quit1",
|
|
||||||
2,
|
|
||||||
"FLOOR7_2",
|
|
||||||
&DoomBorder,
|
|
||||||
0,
|
|
||||||
GAME_Chex,
|
|
||||||
100,
|
|
||||||
"F_SKY1",
|
|
||||||
24*FRACUNIT,
|
|
||||||
"xlat/doom.txt",
|
|
||||||
{ "mapinfo/chex.txt", NULL },
|
|
||||||
MAKERGB(63,125,57),
|
|
||||||
MAKERGB(95,175,87),
|
|
||||||
"ZorchPack",
|
|
||||||
"sbarinfo/doom.txt",
|
|
||||||
};
|
|
||||||
|
|
||||||
gameinfo_t Chex3GameInfo =
|
#define GAMEINFOKEY_COLOR(key, variable) \
|
||||||
{
|
else if(nextKey.CompareNoCase(variable) == 0) \
|
||||||
GI_CHEX_QUEST,
|
{ \
|
||||||
"TITLEPIC",
|
sc.MustGetToken(TK_StringConst); \
|
||||||
"ENDPIC",
|
FString color = sc.String; \
|
||||||
"VICTORY2",
|
FString colorName = V_GetColorStringByName(color); \
|
||||||
"$MUSIC_INTRO",
|
if(!colorName.IsEmpty()) \
|
||||||
5,
|
color = colorName; \
|
||||||
0,
|
gameinfo.key = V_GetColorFromString(NULL, color); \
|
||||||
200/35,
|
}
|
||||||
"misc/chat2",
|
|
||||||
"$MUSIC_VICTOR",
|
|
||||||
"ENDPIC01",
|
|
||||||
"CREDIT",
|
|
||||||
"CREDIT",
|
|
||||||
"ENDPIC",
|
|
||||||
{ { "HELP1", "CREDIT" } },
|
|
||||||
"menu/quit1",
|
|
||||||
2,
|
|
||||||
"FLOOR7_2",
|
|
||||||
&DoomBorder,
|
|
||||||
0,
|
|
||||||
GAME_Chex,
|
|
||||||
100,
|
|
||||||
"F_SKY1",
|
|
||||||
24*FRACUNIT,
|
|
||||||
"xlat/doom.txt",
|
|
||||||
{ "mapinfo/chex.txt", NULL },
|
|
||||||
MAKERGB(63,125,57),
|
|
||||||
MAKERGB(95,175,87),
|
|
||||||
"ZorchPack",
|
|
||||||
"sbarinfo/doom.txt",
|
|
||||||
};
|
|
||||||
|
|
||||||
gameinfo_t RetailGameInfo =
|
#define GAMEINFOKEY_BOOL(key, variable) \
|
||||||
{
|
else if(nextKey.CompareNoCase(variable) == 0) \
|
||||||
GI_MENUHACK_RETAIL,
|
{ \
|
||||||
"TITLEPIC",
|
if(sc.CheckToken(TK_False)) \
|
||||||
"CREDIT",
|
gameinfo.key = false; \
|
||||||
"CREDIT",
|
else \
|
||||||
"$MUSIC_INTRO",
|
{ \
|
||||||
5,
|
sc.MustGetToken(TK_True); \
|
||||||
0,
|
gameinfo.key = true; \
|
||||||
200/35,
|
} \
|
||||||
"misc/chat2",
|
}
|
||||||
"$MUSIC_VICTOR",
|
|
||||||
"FLOOR4_8",
|
|
||||||
"CREDIT",
|
|
||||||
"VICTORY2",
|
|
||||||
"ENDPIC",
|
|
||||||
{ { "HELP1", "CREDIT" } },
|
|
||||||
"menu/quit1",
|
|
||||||
2,
|
|
||||||
"FLOOR7_2",
|
|
||||||
&DoomBorder,
|
|
||||||
0,
|
|
||||||
GAME_Doom,
|
|
||||||
100,
|
|
||||||
"F_SKY1",
|
|
||||||
24*FRACUNIT,
|
|
||||||
"xlat/doom.txt",
|
|
||||||
{ "mapinfo/doomcommon.txt", "mapinfo/doom1.txt" },
|
|
||||||
MAKERGB(104,0,0),
|
|
||||||
MAKERGB(255,0,0),
|
|
||||||
"Backpack",
|
|
||||||
"sbarinfo/doom.txt",
|
|
||||||
};
|
|
||||||
|
|
||||||
gameinfo_t CommercialGameInfo =
|
void FMapInfoParser::ParseGameInfo()
|
||||||
{
|
{
|
||||||
GI_MAPxx | GI_MENUHACK_COMMERCIAL,
|
sc.MustGetToken('{');
|
||||||
"TITLEPIC",
|
while(sc.GetToken())
|
||||||
"CREDIT",
|
{
|
||||||
"CREDIT",
|
if (sc.TokenType == '}') return;
|
||||||
"$MUSIC_DM2TTL",
|
|
||||||
11,
|
|
||||||
0,
|
|
||||||
200/35,
|
|
||||||
"misc/chat",
|
|
||||||
"$MUSIC_READ_M",
|
|
||||||
"SLIME16",
|
|
||||||
"CREDIT",
|
|
||||||
"CREDIT",
|
|
||||||
"CREDIT",
|
|
||||||
{ { "HELP", "CREDIT" } },
|
|
||||||
"menu/quit2",
|
|
||||||
3,
|
|
||||||
"GRNROCK",
|
|
||||||
&DoomBorder,
|
|
||||||
0,
|
|
||||||
GAME_Doom,
|
|
||||||
100,
|
|
||||||
"F_SKY1",
|
|
||||||
24*FRACUNIT,
|
|
||||||
"xlat/doom.txt",
|
|
||||||
{ "mapinfo/doomcommon.txt", "mapinfo/doom2.txt" },
|
|
||||||
MAKERGB(104,0,0),
|
|
||||||
MAKERGB(255,0,0),
|
|
||||||
"Backpack",
|
|
||||||
"sbarinfo/doom.txt",
|
|
||||||
};
|
|
||||||
|
|
||||||
gameinfo_t PlutoniaGameInfo =
|
sc.TokenMustBe(TK_Identifier);
|
||||||
{
|
FString nextKey = sc.String;
|
||||||
GI_MAPxx | GI_MENUHACK_COMMERCIAL,
|
sc.MustGetToken('=');
|
||||||
"TITLEPIC",
|
|
||||||
"CREDIT",
|
|
||||||
"CREDIT",
|
|
||||||
"$MUSIC_DM2TTL",
|
|
||||||
11,
|
|
||||||
0,
|
|
||||||
200/35,
|
|
||||||
"misc/chat",
|
|
||||||
"$MUSIC_READ_M",
|
|
||||||
"SLIME16",
|
|
||||||
"CREDIT",
|
|
||||||
"CREDIT",
|
|
||||||
"CREDIT",
|
|
||||||
{ { "HELP", "CREDIT" } },
|
|
||||||
"menu/quit2",
|
|
||||||
3,
|
|
||||||
"GRNROCK",
|
|
||||||
&DoomBorder,
|
|
||||||
0,
|
|
||||||
GAME_Doom,
|
|
||||||
100,
|
|
||||||
"F_SKY1",
|
|
||||||
24*FRACUNIT,
|
|
||||||
"xlat/doom.txt",
|
|
||||||
{ "mapinfo/doomcommon.txt", "mapinfo/plutonia.txt" },
|
|
||||||
MAKERGB(104,0,0),
|
|
||||||
MAKERGB(255,0,0),
|
|
||||||
"Backpack",
|
|
||||||
"sbarinfo/doom.txt",
|
|
||||||
};
|
|
||||||
|
|
||||||
gameinfo_t TNTGameInfo =
|
if(nextKey.CompareNoCase("border") == 0)
|
||||||
{
|
{
|
||||||
GI_MAPxx | GI_MENUHACK_COMMERCIAL,
|
if(sc.CheckToken(TK_Identifier))
|
||||||
"TITLEPIC",
|
{
|
||||||
"CREDIT",
|
switch(sc.MustMatchString(GameInfoBoarders))
|
||||||
"CREDIT",
|
{
|
||||||
"$MUSIC_DM2TTL",
|
default:
|
||||||
11,
|
gameinfo.border = &DoomBorder;
|
||||||
0,
|
break;
|
||||||
200/35,
|
case 1:
|
||||||
"misc/chat",
|
gameinfo.border = &HereticBorder;
|
||||||
"$MUSIC_READ_M",
|
break;
|
||||||
"SLIME16",
|
case 2:
|
||||||
"CREDIT",
|
gameinfo.border = &StrifeBorder;
|
||||||
"CREDIT",
|
break;
|
||||||
"CREDIT",
|
}
|
||||||
{ { "HELP", "CREDIT" } },
|
}
|
||||||
"menu/quit2",
|
else
|
||||||
3,
|
{
|
||||||
"GRNROCK",
|
// border = {size, offset, tr, t, tl, r, l ,br, b, bl};
|
||||||
&DoomBorder,
|
char *graphics[8] = {DoomBorder.tr, DoomBorder.t, DoomBorder.tl, DoomBorder.r, DoomBorder.l, DoomBorder.br, DoomBorder.b, DoomBorder.bl};
|
||||||
0,
|
sc.MustGetToken('{');
|
||||||
GAME_Doom,
|
sc.MustGetToken(TK_IntConst);
|
||||||
100,
|
DoomBorder.offset = sc.Number;
|
||||||
"F_SKY1",
|
sc.MustGetToken(',');
|
||||||
24*FRACUNIT,
|
sc.MustGetToken(TK_IntConst);
|
||||||
"xlat/doom.txt",
|
DoomBorder.size = sc.Number;
|
||||||
{ "mapinfo/doomcommon.txt", "mapinfo/tnt.txt" },
|
for(int i = 0;i < 8;i++)
|
||||||
MAKERGB(104,0,0),
|
{
|
||||||
MAKERGB(255,0,0),
|
sc.MustGetToken(',');
|
||||||
"Backpack",
|
sc.MustGetToken(TK_StringConst);
|
||||||
"sbarinfo/doom.txt",
|
int len = int(strlen(sc.String));
|
||||||
};
|
if(len > 8)
|
||||||
|
sc.ScriptError("Border graphic can not be more than 8 characters long.\n");
|
||||||
|
memcpy(graphics[i], sc.String, len);
|
||||||
|
if(len < 8) // end with a null byte if the string is less than 8 chars.
|
||||||
|
graphics[i][len] = 0;
|
||||||
|
}
|
||||||
|
sc.MustGetToken('}');
|
||||||
|
}
|
||||||
|
}
|
||||||
|
// Insert valid keys here.
|
||||||
|
GAMEINFOKEY_CSTRING(titlePage, "titlePage", 8)
|
||||||
|
GAMEINFOKEY_STRINGARRAY(creditPages, "creditPage", 8)
|
||||||
|
GAMEINFOKEY_STRING(titleMusic, "titleMusic")
|
||||||
|
GAMEINFOKEY_FLOAT(titleTime, "titleTime")
|
||||||
|
GAMEINFOKEY_FLOAT(advisoryTime, "advisoryTime")
|
||||||
|
GAMEINFOKEY_FLOAT(pageTime, "pageTime")
|
||||||
|
GAMEINFOKEY_STRING(chatSound, "chatSound")
|
||||||
|
GAMEINFOKEY_STRING(finaleMusic, "finaleMusic")
|
||||||
|
GAMEINFOKEY_CSTRING(finaleFlat, "finaleFlat", 8)
|
||||||
|
GAMEINFOKEY_STRINGARRAY(finalePages, "finalePage", 8)
|
||||||
|
GAMEINFOKEY_STRINGARRAY(infoPages, "infoPage", 8)
|
||||||
|
GAMEINFOKEY_STRING(quitSound, "quitSound")
|
||||||
|
GAMEINFOKEY_CSTRING(borderFlat, "borderFlat", 8)
|
||||||
|
GAMEINFOKEY_FIXED(telefogheight, "telefogheight")
|
||||||
|
GAMEINFOKEY_INT(defKickback, "defKickback")
|
||||||
|
GAMEINFOKEY_CSTRING(SkyFlatName, "SkyFlatName", 8)
|
||||||
|
GAMEINFOKEY_STRING(translator, "translator")
|
||||||
|
GAMEINFOKEY_COLOR(defaultbloodcolor, "defaultbloodcolor")
|
||||||
|
GAMEINFOKEY_COLOR(defaultbloodparticlecolor, "defaultbloodparticlecolor")
|
||||||
|
GAMEINFOKEY_STRING(backpacktype, "backpacktype")
|
||||||
|
GAMEINFOKEY_STRING(statusbar, "statusbar")
|
||||||
|
GAMEINFOKEY_STRING(intermissionMusic, "intermissionMusic")
|
||||||
|
GAMEINFOKEY_BOOL(noloopfinalemusic, "noloopfinalemusic")
|
||||||
|
GAMEINFOKEY_BOOL(drawreadthis, "drawreadthis")
|
||||||
|
else
|
||||||
|
{
|
||||||
|
// ignore unkown keys.
|
||||||
|
sc.UnGet();
|
||||||
|
SkipToNext();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
gameinfo_t StrifeGameInfo =
|
const char *gameinfo_t::GetFinalePage(unsigned int num) const
|
||||||
{
|
{
|
||||||
GI_MAPxx | GI_INFOINDEXED | GI_ALWAYSFALLINGDAMAGE,
|
if (finalePages.Size() == 0) return "-NOFLAT-";
|
||||||
"TITLEPIC",
|
else if (num < 1 || num > finalePages.Size()) return finalePages[0];
|
||||||
"CREDIT",
|
else return finalePages[num-1];
|
||||||
"CREDIT",
|
}
|
||||||
"D_LOGO",
|
|
||||||
280/35,
|
|
||||||
0,
|
|
||||||
200/35,
|
|
||||||
"misc/chat",
|
|
||||||
"d_intro",
|
|
||||||
"-NOFLAT",
|
|
||||||
"CREDIT",
|
|
||||||
"CREDIT",
|
|
||||||
"CREDIT",
|
|
||||||
{ { "CREDIT", {4} } },
|
|
||||||
NULL,
|
|
||||||
49,
|
|
||||||
"F_PAVE01",
|
|
||||||
&StrifeBorder,
|
|
||||||
0,
|
|
||||||
GAME_Strife,
|
|
||||||
150,
|
|
||||||
"F_SKY001",
|
|
||||||
16*FRACUNIT,
|
|
||||||
"xlat/strife.txt",
|
|
||||||
{ "mapinfo/strife.txt", NULL },
|
|
||||||
MAKERGB(104,0,0),
|
|
||||||
MAKERGB(255,0,0),
|
|
||||||
"AmmoSatchel",
|
|
||||||
NULL,
|
|
||||||
};
|
|
||||||
|
|
||||||
gameinfo_t StrifeTeaserGameInfo =
|
|
||||||
{
|
|
||||||
GI_MAPxx | GI_INFOINDEXED | GI_ALWAYSFALLINGDAMAGE | GI_SHAREWARE,
|
|
||||||
"TITLEPIC",
|
|
||||||
"CREDIT",
|
|
||||||
"CREDIT",
|
|
||||||
"D_LOGO",
|
|
||||||
280/35,
|
|
||||||
0,
|
|
||||||
200/35,
|
|
||||||
"misc/chat",
|
|
||||||
"d_intro",
|
|
||||||
"-NOFLAT",
|
|
||||||
"CREDIT",
|
|
||||||
"CREDIT",
|
|
||||||
"CREDIT",
|
|
||||||
{ { "CREDIT", {4} } },
|
|
||||||
NULL,
|
|
||||||
49,
|
|
||||||
"F_PAVE01",
|
|
||||||
&StrifeBorder,
|
|
||||||
0,
|
|
||||||
GAME_Strife,
|
|
||||||
150,
|
|
||||||
"F_SKY001",
|
|
||||||
16*FRACUNIT,
|
|
||||||
"xlat/strife.txt",
|
|
||||||
{ "mapinfo/strife.txt", NULL },
|
|
||||||
MAKERGB(104,0,0),
|
|
||||||
MAKERGB(255,0,0),
|
|
||||||
"AmmoSatchel",
|
|
||||||
NULL,
|
|
||||||
};
|
|
||||||
|
|
||||||
gameinfo_t StrifeTeaser2GameInfo =
|
|
||||||
{
|
|
||||||
GI_MAPxx | GI_INFOINDEXED | GI_ALWAYSFALLINGDAMAGE | GI_SHAREWARE | GI_TEASER2,
|
|
||||||
"TITLEPIC",
|
|
||||||
"CREDIT",
|
|
||||||
"CREDIT",
|
|
||||||
"D_LOGO",
|
|
||||||
280/35,
|
|
||||||
0,
|
|
||||||
200/35,
|
|
||||||
"misc/chat",
|
|
||||||
"d_intro",
|
|
||||||
"-NOFLAT",
|
|
||||||
"CREDIT",
|
|
||||||
"CREDIT",
|
|
||||||
"CREDIT",
|
|
||||||
{ { "CREDIT", {4} } },
|
|
||||||
NULL,
|
|
||||||
49,
|
|
||||||
"F_PAVE01",
|
|
||||||
&StrifeBorder,
|
|
||||||
0,
|
|
||||||
GAME_Strife,
|
|
||||||
150,
|
|
||||||
"F_SKY001",
|
|
||||||
16*FRACUNIT,
|
|
||||||
"xlat/strife.txt",
|
|
||||||
{ "mapinfo/strife.txt", NULL },
|
|
||||||
MAKERGB(104,0,0),
|
|
||||||
MAKERGB(255,0,0),
|
|
||||||
"AmmoSatchel",
|
|
||||||
NULL,
|
|
||||||
};
|
|
||||||
|
|
78
src/gi.h
78
src/gi.h
|
@ -35,37 +35,15 @@
|
||||||
#define __GI_H__
|
#define __GI_H__
|
||||||
|
|
||||||
#include "basictypes.h"
|
#include "basictypes.h"
|
||||||
|
#include "zstring.h"
|
||||||
|
|
||||||
|
// Flags are not user configurable and only depend on the standard IWADs
|
||||||
#define GI_MAPxx 0x00000001
|
#define GI_MAPxx 0x00000001
|
||||||
#define GI_PAGESARERAW 0x00000002
|
#define GI_SHAREWARE 0x00000002
|
||||||
#define GI_SHAREWARE 0x00000004
|
#define GI_MENUHACK_EXTENDED 0x00000004 // (Heretic)
|
||||||
#define GI_NOLOOPFINALEMUSIC 0x00000008
|
#define GI_TEASER2 0x00000008 // Alternate version of the Strife Teaser
|
||||||
#define GI_INFOINDEXED 0x00000010
|
|
||||||
#define GI_MENUHACK 0x00000060
|
|
||||||
#define GI_MENUHACK_RETAIL 0x00000020
|
|
||||||
#define GI_MENUHACK_EXTENDED 0x00000040 // (Heretic)
|
|
||||||
#define GI_MENUHACK_COMMERCIAL 0x00000060
|
|
||||||
#define GI_ALWAYSFALLINGDAMAGE 0x00000080
|
|
||||||
#define GI_TEASER2 0x00000100 // Alternate version of the Strife Teaser
|
|
||||||
#define GI_CHEX_QUEST 0x00000200
|
|
||||||
|
|
||||||
#ifndef EGAMETYPE
|
#include "gametype.h"
|
||||||
#define EGAMETYPE
|
|
||||||
enum EGameType
|
|
||||||
{
|
|
||||||
GAME_Any = 0,
|
|
||||||
GAME_Doom = 1,
|
|
||||||
GAME_Heretic = 2,
|
|
||||||
GAME_Hexen = 4,
|
|
||||||
GAME_Strife = 8,
|
|
||||||
GAME_Chex = 16, //Chex is basically Doom, but we need to have a different set of actors.
|
|
||||||
|
|
||||||
GAME_Raven = GAME_Heretic|GAME_Hexen,
|
|
||||||
GAME_DoomStrife = GAME_Doom|GAME_Strife,
|
|
||||||
GAME_DoomChex = GAME_Doom|GAME_Chex,
|
|
||||||
GAME_DoomStrifeChex = GAME_Doom|GAME_Strife|GAME_Chex
|
|
||||||
};
|
|
||||||
#endif
|
|
||||||
|
|
||||||
extern const char *GameNames[17];
|
extern const char *GameNames[17];
|
||||||
|
|
||||||
|
@ -86,45 +64,39 @@ typedef struct
|
||||||
typedef struct
|
typedef struct
|
||||||
{
|
{
|
||||||
int flags;
|
int flags;
|
||||||
|
EGameType gametype;
|
||||||
|
|
||||||
char titlePage[9];
|
char titlePage[9];
|
||||||
char creditPage1[9];
|
bool drawreadthis;
|
||||||
char creditPage2[9];
|
bool noloopfinalemusic;
|
||||||
char titleMusic[16];
|
TArray<FName> creditPages;
|
||||||
|
TArray<FName> finalePages;
|
||||||
|
TArray<FName> infoPages;
|
||||||
|
|
||||||
|
FString titleMusic;
|
||||||
float titleTime;
|
float titleTime;
|
||||||
float advisoryTime;
|
float advisoryTime;
|
||||||
float pageTime;
|
float pageTime;
|
||||||
char chatSound[16];
|
FString chatSound;
|
||||||
char finaleMusic[16];
|
FString finaleMusic;
|
||||||
char finaleFlat[9];
|
char finaleFlat[9];
|
||||||
char finalePage1[9];
|
FString quitSound;
|
||||||
char finalePage2[9];
|
|
||||||
char finalePage3[9];
|
|
||||||
union
|
|
||||||
{
|
|
||||||
char infoPage[2][9];
|
|
||||||
struct
|
|
||||||
{
|
|
||||||
char basePage[9];
|
|
||||||
char numPages;
|
|
||||||
} indexed;
|
|
||||||
} info;
|
|
||||||
const char *quitSound;
|
|
||||||
int maxSwitch;
|
|
||||||
char borderFlat[9];
|
char borderFlat[9];
|
||||||
gameborder_t *border;
|
gameborder_t *border;
|
||||||
int telefogheight;
|
int telefogheight;
|
||||||
EGameType gametype;
|
|
||||||
int defKickback;
|
int defKickback;
|
||||||
char SkyFlatName[9];
|
char SkyFlatName[9];
|
||||||
fixed_t StepHeight;
|
FString translator;
|
||||||
const char *translator;
|
|
||||||
const char *mapinfo[2];
|
|
||||||
DWORD defaultbloodcolor;
|
DWORD defaultbloodcolor;
|
||||||
DWORD defaultbloodparticlecolor;
|
DWORD defaultbloodparticlecolor;
|
||||||
const char *backpacktype;
|
FString backpacktype;
|
||||||
const char *statusbar;
|
FString statusbar;
|
||||||
|
FString intermissionMusic;
|
||||||
|
|
||||||
|
const char *GetFinalePage(unsigned int num) const;
|
||||||
} gameinfo_t;
|
} gameinfo_t;
|
||||||
|
|
||||||
|
|
||||||
extern gameinfo_t gameinfo;
|
extern gameinfo_t gameinfo;
|
||||||
|
|
||||||
#endif //__GI_H__
|
#endif //__GI_H__
|
||||||
|
|
18
src/info.h
18
src/info.h
|
@ -142,23 +142,7 @@ struct FStateLabels
|
||||||
|
|
||||||
FArchive &operator<< (FArchive &arc, FState *&state);
|
FArchive &operator<< (FArchive &arc, FState *&state);
|
||||||
|
|
||||||
#ifndef EGAMETYPE
|
#include "gametype.h"
|
||||||
#define EGAMETYPE
|
|
||||||
enum EGameType
|
|
||||||
{
|
|
||||||
GAME_Any = 0,
|
|
||||||
GAME_Doom = 1,
|
|
||||||
GAME_Heretic = 2,
|
|
||||||
GAME_Hexen = 4,
|
|
||||||
GAME_Strife = 8,
|
|
||||||
GAME_Chex = 16,
|
|
||||||
|
|
||||||
GAME_Raven = GAME_Heretic|GAME_Hexen,
|
|
||||||
GAME_DoomStrife = GAME_Doom|GAME_Strife,
|
|
||||||
GAME_DoomChex = GAME_Doom|GAME_Chex,
|
|
||||||
GAME_DoomStrifeChex = GAME_Doom|GAME_Strife|GAME_Chex
|
|
||||||
};
|
|
||||||
#endif
|
|
||||||
|
|
||||||
typedef TMap<FName, fixed_t> DmgFactors;
|
typedef TMap<FName, fixed_t> DmgFactors;
|
||||||
typedef TMap<FName, BYTE> PainChanceList;
|
typedef TMap<FName, BYTE> PainChanceList;
|
||||||
|
|
|
@ -1460,36 +1460,23 @@ void M_DrawReadThis ()
|
||||||
FTexture *tex = NULL, *prevpic = NULL;
|
FTexture *tex = NULL, *prevpic = NULL;
|
||||||
fixed_t alpha;
|
fixed_t alpha;
|
||||||
|
|
||||||
if (gameinfo.flags & GI_INFOINDEXED)
|
// Did the mapper choose a custom help page via MAPINFO?
|
||||||
|
if ((level.info != NULL) && level.info->f1[0] != 0)
|
||||||
{
|
{
|
||||||
char name[9];
|
tex = TexMan.FindTexture(level.info->f1);
|
||||||
name[8] = 0;
|
InfoType = 1;
|
||||||
Wads.GetLumpName (name, Wads.GetNumForName (gameinfo.info.indexed.basePage, ns_graphics) + InfoType);
|
|
||||||
tex = TexMan[name];
|
|
||||||
if (InfoType > 1)
|
|
||||||
{
|
|
||||||
Wads.GetLumpName (name, Wads.GetNumForName (gameinfo.info.indexed.basePage, ns_graphics) + InfoType - 1);
|
|
||||||
prevpic = TexMan[name];
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
else
|
|
||||||
|
if (tex == NULL)
|
||||||
{
|
{
|
||||||
// Did the mapper choose a custom help page via MAPINFO?
|
tex = TexMan[gameinfo.infoPages[InfoType-1].GetChars()];
|
||||||
if ((level.info != NULL) && level.info->f1[0] != 0)
|
|
||||||
{
|
|
||||||
tex = TexMan.FindTexture(level.info->f1);
|
|
||||||
}
|
|
||||||
|
|
||||||
if (tex == NULL)
|
|
||||||
{
|
|
||||||
tex = TexMan[gameinfo.info.infoPage[InfoType-1]];
|
|
||||||
}
|
|
||||||
|
|
||||||
if (InfoType > 1)
|
|
||||||
{
|
|
||||||
prevpic = TexMan[gameinfo.info.infoPage[InfoType-2]];
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (InfoType > 1)
|
||||||
|
{
|
||||||
|
prevpic = TexMan[gameinfo.infoPages[InfoType-2].GetChars()];
|
||||||
|
}
|
||||||
|
|
||||||
alpha = MIN<fixed_t> (Scale (gametic - InfoTic, OPAQUE, TICRATE/3), OPAQUE);
|
alpha = MIN<fixed_t> (Scale (gametic - InfoTic, OPAQUE, TICRATE/3), OPAQUE);
|
||||||
if (alpha < OPAQUE && prevpic != NULL)
|
if (alpha < OPAQUE && prevpic != NULL)
|
||||||
{
|
{
|
||||||
|
@ -1975,14 +1962,7 @@ void M_ReadThisMore (int choice)
|
||||||
{
|
{
|
||||||
InfoType++;
|
InfoType++;
|
||||||
InfoTic = gametic;
|
InfoTic = gametic;
|
||||||
if (gameinfo.flags & GI_INFOINDEXED)
|
if ((level.info != NULL && level.info->f1[0] != 0) || InfoType > int(gameinfo.infoPages.Size()))
|
||||||
{
|
|
||||||
if (InfoType >= gameinfo.info.indexed.numPages)
|
|
||||||
{
|
|
||||||
M_FinishReadThis (0);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
else if (InfoType > 2)
|
|
||||||
{
|
{
|
||||||
M_FinishReadThis (0);
|
M_FinishReadThis (0);
|
||||||
}
|
}
|
||||||
|
@ -3504,19 +3484,15 @@ void M_Init (void)
|
||||||
LINEHEIGHT = 20;
|
LINEHEIGHT = 20;
|
||||||
}
|
}
|
||||||
|
|
||||||
switch (gameinfo.flags & GI_MENUHACK)
|
if (!gameinfo.drawreadthis)
|
||||||
{
|
{
|
||||||
case GI_MENUHACK_COMMERCIAL:
|
|
||||||
MainMenu[MainDef.numitems-2] = MainMenu[MainDef.numitems-1];
|
MainMenu[MainDef.numitems-2] = MainMenu[MainDef.numitems-1];
|
||||||
MainDef.numitems--;
|
MainDef.numitems--;
|
||||||
MainDef.y += 8;
|
MainDef.y += 8;
|
||||||
ReadDef.routine = M_DrawReadThis;
|
ReadDef.routine = M_DrawReadThis;
|
||||||
ReadDef.x = 330;
|
ReadDef.x = 330;
|
||||||
ReadDef.y = 165;
|
ReadDef.y = 165;
|
||||||
ReadMenu[0].routine = M_FinishReadThis;
|
//ReadMenu[0].routine = M_FinishReadThis;
|
||||||
break;
|
|
||||||
default:
|
|
||||||
break;
|
|
||||||
}
|
}
|
||||||
M_OptInit ();
|
M_OptInit ();
|
||||||
|
|
||||||
|
|
|
@ -162,16 +162,21 @@ static bool PIT_FindFloorCeiling (line_t *ld, const FBoundingBox &box, FCheckPos
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
void P_GetFloorCeilingZ(FCheckPosition &tmf)
|
void P_GetFloorCeilingZ(FCheckPosition &tmf, bool get)
|
||||||
{
|
{
|
||||||
sector_t *sec = P_PointInSector (tmf.x, tmf.y);
|
sector_t *sec;
|
||||||
tmf.floorsector = sec;
|
if (get)
|
||||||
tmf.ceilingsector = sec;
|
{
|
||||||
|
sec = P_PointInSector (tmf.x, tmf.y);
|
||||||
|
tmf.floorsector = sec;
|
||||||
|
tmf.ceilingsector = sec;
|
||||||
|
|
||||||
tmf.floorz = tmf.dropoffz = sec->floorplane.ZatPoint (tmf.x, tmf.y);
|
tmf.floorz = tmf.dropoffz = sec->floorplane.ZatPoint (tmf.x, tmf.y);
|
||||||
tmf.ceilingz = sec->ceilingplane.ZatPoint (tmf.x, tmf.y);
|
tmf.ceilingz = sec->ceilingplane.ZatPoint (tmf.x, tmf.y);
|
||||||
tmf.floorpic = sec->GetTexture(sector_t::floor);
|
tmf.floorpic = sec->GetTexture(sector_t::floor);
|
||||||
tmf.ceilingpic = sec->GetTexture(sector_t::ceiling);
|
tmf.ceilingpic = sec->GetTexture(sector_t::ceiling);
|
||||||
|
}
|
||||||
|
else sec = tmf.thing->Sector;
|
||||||
|
|
||||||
#ifdef _3DFLOORS
|
#ifdef _3DFLOORS
|
||||||
for(unsigned int i=0;i<sec->e->XFloor.ffloors.Size();i++)
|
for(unsigned int i=0;i<sec->e->XFloor.ffloors.Size();i++)
|
||||||
|
@ -217,14 +222,7 @@ void P_FindFloorCeiling (AActor *actor, bool onlyspawnpos)
|
||||||
|
|
||||||
if (!onlyspawnpos)
|
if (!onlyspawnpos)
|
||||||
{
|
{
|
||||||
P_GetFloorCeilingZ(tmf);
|
P_GetFloorCeilingZ(tmf, true);
|
||||||
actor->floorz = tmf.floorz;
|
|
||||||
actor->dropoffz = tmf.dropoffz;
|
|
||||||
actor->ceilingz = tmf.ceilingz;
|
|
||||||
actor->floorpic = tmf.floorpic;
|
|
||||||
actor->floorsector = tmf.floorsector;
|
|
||||||
actor->ceilingpic = tmf.ceilingpic;
|
|
||||||
actor->ceilingsector = tmf.ceilingsector;
|
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
@ -234,7 +232,15 @@ void P_FindFloorCeiling (AActor *actor, bool onlyspawnpos)
|
||||||
tmf.ceilingz = actor->ceilingz;
|
tmf.ceilingz = actor->ceilingz;
|
||||||
tmf.floorpic = actor->floorpic;
|
tmf.floorpic = actor->floorpic;
|
||||||
tmf.ceilingpic = actor->ceilingpic;
|
tmf.ceilingpic = actor->ceilingpic;
|
||||||
|
P_GetFloorCeilingZ(tmf, false);
|
||||||
}
|
}
|
||||||
|
actor->floorz = tmf.floorz;
|
||||||
|
actor->dropoffz = tmf.dropoffz;
|
||||||
|
actor->ceilingz = tmf.ceilingz;
|
||||||
|
actor->floorpic = tmf.floorpic;
|
||||||
|
actor->floorsector = tmf.floorsector;
|
||||||
|
actor->ceilingpic = tmf.ceilingpic;
|
||||||
|
actor->ceilingsector = tmf.ceilingsector;
|
||||||
|
|
||||||
FBoundingBox box(tmf.x, tmf.y, actor->radius);
|
FBoundingBox box(tmf.x, tmf.y, actor->radius);
|
||||||
|
|
||||||
|
@ -293,7 +299,7 @@ bool P_TeleportMove (AActor *thing, fixed_t x, fixed_t y, fixed_t z, bool telefr
|
||||||
tmf.x = x;
|
tmf.x = x;
|
||||||
tmf.y = y;
|
tmf.y = y;
|
||||||
tmf.z = z;
|
tmf.z = z;
|
||||||
P_GetFloorCeilingZ(tmf);
|
P_GetFloorCeilingZ(tmf, true);
|
||||||
|
|
||||||
spechit.Clear ();
|
spechit.Clear ();
|
||||||
|
|
||||||
|
|
|
@ -3370,7 +3370,7 @@ void P_SetupLevel (char *lumpname, int position)
|
||||||
{
|
{
|
||||||
// We need translators only for Doom format maps.
|
// We need translators only for Doom format maps.
|
||||||
// If none has been defined in a map use the game's default.
|
// If none has been defined in a map use the game's default.
|
||||||
P_LoadTranslator(!level.info->Translator.IsEmpty()? level.info->Translator.GetChars() : gameinfo.translator);
|
P_LoadTranslator(!level.info->Translator.IsEmpty()? level.info->Translator.GetChars() : gameinfo.translator.GetChars());
|
||||||
}
|
}
|
||||||
CheckCompatibility(map);
|
CheckCompatibility(map);
|
||||||
|
|
||||||
|
|
|
@ -143,10 +143,9 @@ void P_InitSwitchList ()
|
||||||
Printf ("Switch %s in SWITCHES has the same 'on' state\n", list_p);
|
Printf ("Switch %s in SWITCHES has the same 'on' state\n", list_p);
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
// [RH] Skip this switch if its texture can't be found.
|
// [RH] Skip this switch if its textures can't be found.
|
||||||
if (((gameinfo.maxSwitch & 15) >= (list_p[18] & 15)) &&
|
if (TexMan.CheckForTexture (list_p /* .name1 */, FTexture::TEX_Wall, texflags).Exists() &&
|
||||||
((gameinfo.maxSwitch & ~15) == (list_p[18] & ~15)) &&
|
TexMan.CheckForTexture (list_p + 9 /* .name2 */, FTexture::TEX_Wall, texflags).Exists())
|
||||||
TexMan.CheckForTexture (list_p /* .name1 */, FTexture::TEX_Wall, texflags).Exists())
|
|
||||||
{
|
{
|
||||||
def1 = (FSwitchDef *)M_Malloc (sizeof(FSwitchDef));
|
def1 = (FSwitchDef *)M_Malloc (sizeof(FSwitchDef));
|
||||||
def2 = (FSwitchDef *)M_Malloc (sizeof(FSwitchDef));
|
def2 = (FSwitchDef *)M_Malloc (sizeof(FSwitchDef));
|
||||||
|
@ -204,42 +203,40 @@ void P_ProcessSwitchDef (FScanner &sc)
|
||||||
FString picname;
|
FString picname;
|
||||||
FSwitchDef *def1, *def2;
|
FSwitchDef *def1, *def2;
|
||||||
FTextureID picnum;
|
FTextureID picnum;
|
||||||
BYTE max;
|
int gametype;
|
||||||
bool quest = false;
|
bool quest = false;
|
||||||
|
|
||||||
def1 = def2 = NULL;
|
def1 = def2 = NULL;
|
||||||
sc.MustGetString ();
|
sc.MustGetString ();
|
||||||
if (sc.Compare ("doom"))
|
if (sc.Compare ("doom"))
|
||||||
{
|
{
|
||||||
max = 0;
|
gametype = GAME_DoomChex;
|
||||||
|
sc.CheckNumber(); // skip the gamemission filter
|
||||||
}
|
}
|
||||||
else if (sc.Compare ("heretic"))
|
else if (sc.Compare ("heretic"))
|
||||||
{
|
{
|
||||||
max = 17;
|
gametype = GAME_Heretic;
|
||||||
}
|
}
|
||||||
else if (sc.Compare ("hexen"))
|
else if (sc.Compare ("hexen"))
|
||||||
{
|
{
|
||||||
max = 33;
|
gametype = GAME_Hexen;
|
||||||
}
|
}
|
||||||
else if (sc.Compare ("strife"))
|
else if (sc.Compare ("strife"))
|
||||||
{
|
{
|
||||||
max = 49;
|
gametype = GAME_Strife;
|
||||||
}
|
}
|
||||||
else if (sc.Compare ("any"))
|
else if (sc.Compare ("any"))
|
||||||
{
|
{
|
||||||
max = 240;
|
gametype = GAME_Any;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
// There is no game specified; just treat as any
|
// There is no game specified; just treat as any
|
||||||
max = 240;
|
//max = 240;
|
||||||
|
gametype = GAME_Any;
|
||||||
sc.UnGet ();
|
sc.UnGet ();
|
||||||
}
|
}
|
||||||
if (max == 0)
|
|
||||||
{
|
|
||||||
sc.MustGetNumber ();
|
|
||||||
max |= sc.Number & 15;
|
|
||||||
}
|
|
||||||
sc.MustGetString ();
|
sc.MustGetString ();
|
||||||
picnum = TexMan.CheckForTexture (sc.String, FTexture::TEX_Wall, texflags);
|
picnum = TexMan.CheckForTexture (sc.String, FTexture::TEX_Wall, texflags);
|
||||||
picname = sc.String;
|
picname = sc.String;
|
||||||
|
@ -271,16 +268,9 @@ void P_ProcessSwitchDef (FScanner &sc)
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
/*
|
|
||||||
if (def1 == NULL)
|
|
||||||
{
|
|
||||||
sc.ScriptError ("Switch must have an on state");
|
|
||||||
}
|
|
||||||
*/
|
|
||||||
if (def1 == NULL || !picnum.Exists() ||
|
if (def1 == NULL || !picnum.Exists() ||
|
||||||
((max & 240) != 240 &&
|
(gametype != GAME_Any && !(gametype & gameinfo.gametype)))
|
||||||
((gameinfo.maxSwitch & 240) != (max & 240) ||
|
|
||||||
(gameinfo.maxSwitch & 15) < (max & 15))))
|
|
||||||
{
|
{
|
||||||
if (def2 != NULL)
|
if (def2 != NULL)
|
||||||
{
|
{
|
||||||
|
|
|
@ -302,7 +302,7 @@ int FWadCollection::AddExternalFile(const char *filename)
|
||||||
//
|
//
|
||||||
//-----------------------------------------------------------------------
|
//-----------------------------------------------------------------------
|
||||||
|
|
||||||
static DWORD Zip_FindCentralDir(FileReader * fin)
|
DWORD Zip_FindCentralDir(FileReader * fin)
|
||||||
{
|
{
|
||||||
unsigned char buf[BUFREADCOMMENT + 4];
|
unsigned char buf[BUFREADCOMMENT + 4];
|
||||||
DWORD FileSize;
|
DWORD FileSize;
|
||||||
|
|
|
@ -103,6 +103,9 @@ void uppercopy (char *to, const char *from);
|
||||||
// Perform Blood encryption/decryption.
|
// Perform Blood encryption/decryption.
|
||||||
void BloodCrypt (void *data, int key, int len);
|
void BloodCrypt (void *data, int key, int len);
|
||||||
|
|
||||||
|
// Locate central directory in a zip file.
|
||||||
|
DWORD Zip_FindCentralDir(FileReader * fin);
|
||||||
|
|
||||||
// A very loose reference to a lump on disk. This is really just a wrapper
|
// A very loose reference to a lump on disk. This is really just a wrapper
|
||||||
// around the main wad's FILE object with a different length recorded. Since
|
// around the main wad's FILE object with a different length recorded. Since
|
||||||
// two lumps from the same wad share the same FILE, you cannot read from
|
// two lumps from the same wad share the same FILE, you cannot read from
|
||||||
|
|
|
@ -312,7 +312,7 @@ void WI_LoadBackground(bool isenterpic)
|
||||||
{
|
{
|
||||||
case GAME_Chex:
|
case GAME_Chex:
|
||||||
case GAME_Doom:
|
case GAME_Doom:
|
||||||
if (gamemode != commercial)
|
if (!(gameinfo.flags & GI_MAPxx))
|
||||||
{
|
{
|
||||||
const char *level = isenterpic ? wbs->next : wbs->current;
|
const char *level = isenterpic ? wbs->next : wbs->current;
|
||||||
if (IsExMy(level))
|
if (IsExMy(level))
|
||||||
|
@ -332,7 +332,7 @@ void WI_LoadBackground(bool isenterpic)
|
||||||
if (level.info->ExitPic.IsNotEmpty()) return;
|
if (level.info->ExitPic.IsNotEmpty()) return;
|
||||||
|
|
||||||
// E1-E3 need special treatment when playing Doom 1.
|
// E1-E3 need special treatment when playing Doom 1.
|
||||||
if (gamemode!=commercial)
|
if (!(gameinfo.flags & GI_MAPxx))
|
||||||
{
|
{
|
||||||
// not if the last level is not from the first 3 episodes
|
// not if the last level is not from the first 3 episodes
|
||||||
if (!IsExMy(wbs->current)) return;
|
if (!IsExMy(wbs->current)) return;
|
||||||
|
@ -1881,16 +1881,8 @@ void WI_Ticker(void)
|
||||||
// intermission music - use the defaults if none specified
|
// intermission music - use the defaults if none specified
|
||||||
if (level.info->InterMusic.IsNotEmpty())
|
if (level.info->InterMusic.IsNotEmpty())
|
||||||
S_ChangeMusic(level.info->InterMusic, level.info->intermusicorder);
|
S_ChangeMusic(level.info->InterMusic, level.info->intermusicorder);
|
||||||
else if (gameinfo.gametype == GAME_Heretic)
|
|
||||||
S_ChangeMusic ("mus_intr");
|
|
||||||
else if (gameinfo.gametype == GAME_Hexen)
|
|
||||||
S_ChangeMusic ("hub");
|
|
||||||
else if (gameinfo.gametype == GAME_Strife) // Strife also needs a default
|
|
||||||
S_ChangeMusic ("d_slide");
|
|
||||||
else if (gamemode == commercial)
|
|
||||||
S_ChangeMusic ("$MUSIC_DM2INT");
|
|
||||||
else
|
else
|
||||||
S_ChangeMusic ("$MUSIC_INTER");
|
S_ChangeMusic (gameinfo.intermissionMusic.GetChars());
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -1,5 +1,32 @@
|
||||||
// MAPINFO for Chex Quest
|
// MAPINFO for Chex Quest
|
||||||
|
|
||||||
|
gameinfo
|
||||||
|
{
|
||||||
|
titlepage = "TITLEPIC"
|
||||||
|
creditpage = "CREDIT", "HELP1"
|
||||||
|
titlemusic = "$MUSIC_INTRO"
|
||||||
|
titletime = 5
|
||||||
|
advisorytime = 0
|
||||||
|
pagetime = 5
|
||||||
|
chatsound = "misc/chat2"
|
||||||
|
finalemusic = "$MUSIC_VICTOR"
|
||||||
|
finaleflat = "FLOOR4_8"
|
||||||
|
finalepage = "HELP2", "VICTORY2", "ENDPIC"
|
||||||
|
infopage = "HELP1", "CREDIT"
|
||||||
|
quitsound = "menu/quit1"
|
||||||
|
borderflat = "FLOOR7_2"
|
||||||
|
border = DoomBorder
|
||||||
|
telefogheight = 0
|
||||||
|
defkickback = 100
|
||||||
|
skyflatname = "F_SKY1"
|
||||||
|
translator = "xlat/doom.txt"
|
||||||
|
defaultbloodcolor = "3f 7d 39"
|
||||||
|
defaultbloodparticlecolor = "5f af 57"
|
||||||
|
backpacktype = "ZorchPack"
|
||||||
|
statusbar = "sbarinfo/doom.txt"
|
||||||
|
intermissionmusic = "$MUSIC_INTER"
|
||||||
|
}
|
||||||
|
|
||||||
skill baby
|
skill baby
|
||||||
{
|
{
|
||||||
AutoUseHealth
|
AutoUseHealth
|
||||||
|
|
10
wadsrc/static/mapinfo/chex3.txt
Normal file
10
wadsrc/static/mapinfo/chex3.txt
Normal file
|
@ -0,0 +1,10 @@
|
||||||
|
include "mapinfo/chex.txt"
|
||||||
|
|
||||||
|
// Chex Quest 3 gameinfo
|
||||||
|
|
||||||
|
gameinfo
|
||||||
|
{
|
||||||
|
creditpage = "ENDPIC", "VICTORY2"
|
||||||
|
finaleflat = "ENDPIC01"
|
||||||
|
finalepage = "CREDIT", "CREDIT", "ENDPIC"
|
||||||
|
}
|
|
@ -1,4 +1,19 @@
|
||||||
// MAPINFO for Doom 1 (Shareware, Registered, and Retail)
|
// MAPINFO for Doom 1 (Shareware, Registered, and Retail)
|
||||||
|
include "mapinfo/doomcommon.txt"
|
||||||
|
|
||||||
|
gameinfo
|
||||||
|
{
|
||||||
|
creditpage = "CREDIT", "HELP2"
|
||||||
|
titlemusic = "$MUSIC_INTRO"
|
||||||
|
titletime = 5
|
||||||
|
finalemusic = "$MUSIC_VICTOR"
|
||||||
|
finaleflat = "FLOOR4_8"
|
||||||
|
finalepage = "HELP2", "VICTORY2", "ENDPIC"
|
||||||
|
infopage = "HELP1", "HELP2"
|
||||||
|
quitsound = "menu/quit1"
|
||||||
|
borderflat = "FLOOR7_2"
|
||||||
|
drawreadthis = true
|
||||||
|
}
|
||||||
|
|
||||||
clearepisodes
|
clearepisodes
|
||||||
episode e1m1
|
episode e1m1
|
||||||
|
|
|
@ -1,4 +1,5 @@
|
||||||
// MAPINFO for Doom 2
|
// MAPINFO for Doom 2
|
||||||
|
include "mapinfo/doomcommon.txt"
|
||||||
|
|
||||||
clearepisodes
|
clearepisodes
|
||||||
episode map01
|
episode map01
|
||||||
|
|
|
@ -1,3 +1,32 @@
|
||||||
|
|
||||||
|
gameinfo
|
||||||
|
{
|
||||||
|
titlepage = "TITLEPIC"
|
||||||
|
creditpage = "CREDIT"
|
||||||
|
titlemusic = "$MUSIC_DM2TTL"
|
||||||
|
titletime = 11
|
||||||
|
advisorytime = 0
|
||||||
|
pagetime = 5
|
||||||
|
chatsound = "misc/chat"
|
||||||
|
finalemusic = "$MUSIC_READ_M"
|
||||||
|
finaleflat = "SLIME16"
|
||||||
|
finalepage = "CREDIT"
|
||||||
|
infopage = "HELP", "CREDIT"
|
||||||
|
quitsound = "menu/quit2"
|
||||||
|
borderflat = "GRNROCK"
|
||||||
|
border = DoomBorder
|
||||||
|
telefogheight = 0
|
||||||
|
defkickback = 100
|
||||||
|
skyflatname = "F_SKY1"
|
||||||
|
translator = "xlat/doom.txt"
|
||||||
|
mapinfo = "mapinfo/doom2.txt"
|
||||||
|
defaultbloodcolor = "68 00 00"
|
||||||
|
defaultbloodparticlecolor = "ff 00 00"
|
||||||
|
backpacktype = "Backpack"
|
||||||
|
statusbar = "sbarinfo/doom.txt"
|
||||||
|
intermissionmusic = "$MUSIC_INTER"
|
||||||
|
}
|
||||||
|
|
||||||
skill baby
|
skill baby
|
||||||
{
|
{
|
||||||
AutoUseHealth
|
AutoUseHealth
|
||||||
|
|
|
@ -1,5 +1,32 @@
|
||||||
// MAPINFO for Heretic (Shareware and Retail)
|
// MAPINFO for Heretic (Shareware and Retail)
|
||||||
|
|
||||||
|
gameinfo
|
||||||
|
{
|
||||||
|
titlepage = "TITLE"
|
||||||
|
creditpage = "CREDIT"
|
||||||
|
titlemusic = "MUS_TITL"
|
||||||
|
titletime = 8
|
||||||
|
advisorytime = 6
|
||||||
|
pagetime = 5
|
||||||
|
chatsound = "misc/chat"
|
||||||
|
finalemusic = "MUS_CPTD"
|
||||||
|
finaleflat = "FLOOR25"
|
||||||
|
finalepage = "CREDIT"
|
||||||
|
infopage = "HELP1", "HELP2", "CREDIT"
|
||||||
|
quitsound = ""
|
||||||
|
borderflat = "FLAT513"
|
||||||
|
border = HereticBorder
|
||||||
|
telefogheight = 32
|
||||||
|
defkickback = 150
|
||||||
|
skyflatname = "F_SKY1"
|
||||||
|
translator = "xlat/heretic.txt"
|
||||||
|
defaultbloodcolor = "68 00 00"
|
||||||
|
defaultbloodparticlecolor = "ff 00 00"
|
||||||
|
backpacktype = "BagOfHolding"
|
||||||
|
statusbar = ""
|
||||||
|
intermissionmusic = "mus_intr"
|
||||||
|
}
|
||||||
|
|
||||||
skill baby
|
skill baby
|
||||||
{
|
{
|
||||||
AutoUseHealth
|
AutoUseHealth
|
||||||
|
|
8
wadsrc/static/mapinfo/hereticsw.txt
Normal file
8
wadsrc/static/mapinfo/hereticsw.txt
Normal file
|
@ -0,0 +1,8 @@
|
||||||
|
include "mapinfo/heretic.txt"
|
||||||
|
|
||||||
|
gameinfo
|
||||||
|
{
|
||||||
|
finalepage = "ORDER"
|
||||||
|
infopage = "ORDER", "HELP1", "HELP2", "CREDIT"
|
||||||
|
}
|
||||||
|
|
|
@ -2,6 +2,34 @@
|
||||||
|
|
||||||
// Most of the MAPINFO is still in hexen.wad.
|
// Most of the MAPINFO is still in hexen.wad.
|
||||||
|
|
||||||
|
gameinfo
|
||||||
|
{
|
||||||
|
noloopfinalemusic = true
|
||||||
|
titlepage = "TITLE"
|
||||||
|
creditpage = "CREDIT"
|
||||||
|
titlemusic = "HEXEN"
|
||||||
|
titletime = 8
|
||||||
|
advisorytime = 6
|
||||||
|
pagetime = 5
|
||||||
|
chatsound = "Chat"
|
||||||
|
finalemusic = "hub"
|
||||||
|
finaleflat = "-NOFLAT-"
|
||||||
|
finalepage = "CREDIT"
|
||||||
|
infopage = "HELP1", "HELP2", "CREDIT"
|
||||||
|
quitsound = ""
|
||||||
|
borderflat = "F_022"
|
||||||
|
border = HereticBorder
|
||||||
|
telefogheight = 32
|
||||||
|
defkickback = 150
|
||||||
|
skyflatname = "F_SKY"
|
||||||
|
translator = "xlat/heretic.txt" // not really correct but this was used before.
|
||||||
|
defaultbloodcolor = "68 00 00"
|
||||||
|
defaultbloodparticlecolor = "ff 00 00"
|
||||||
|
backpacktype = "BagOfHolding" // Hexen doesn't have a backpack so use Heretic's.
|
||||||
|
statusbar = ""
|
||||||
|
intermissionmusic = "hub"
|
||||||
|
}
|
||||||
|
|
||||||
skill baby
|
skill baby
|
||||||
{
|
{
|
||||||
AutoUseHealth
|
AutoUseHealth
|
||||||
|
|
|
@ -1,7 +1,8 @@
|
||||||
// MAPINFO for Plutonia. Exactly the same as Doom 2, except it
|
// MAPINFO for Plutonia. Exactly the same as Doom 2, except it
|
||||||
|
|
||||||
// has different map names and cluster messages.
|
// has different map names and cluster messages.
|
||||||
|
|
||||||
|
include "mapinfo/doomcommon.txt"
|
||||||
|
|
||||||
clearepisodes
|
clearepisodes
|
||||||
episode map01
|
episode map01
|
||||||
{
|
{
|
||||||
|
|
|
@ -1,5 +1,32 @@
|
||||||
// MAPINFO for Strife (full version and teaser)
|
// MAPINFO for Strife (full version and teaser)
|
||||||
|
|
||||||
|
gameinfo
|
||||||
|
{
|
||||||
|
titlepage = "TITLEPIC"
|
||||||
|
creditpage = "CREDIT"
|
||||||
|
titlemusic = "D_LOGO"
|
||||||
|
titletime = 8
|
||||||
|
advisorytime = 0
|
||||||
|
pagetime = 5
|
||||||
|
chatsound = "misc/chat"
|
||||||
|
finalemusic = "d_intro"
|
||||||
|
finaleflat = "-NOFLAT-"
|
||||||
|
finalepage = "CREDIT"
|
||||||
|
infopage = "HELP1", "HELP2", "HELP3"
|
||||||
|
quitsound = ""
|
||||||
|
borderflat = "F_PAVE01"
|
||||||
|
border = StrifeBorder
|
||||||
|
telefogheight = 0
|
||||||
|
defkickback = 150
|
||||||
|
skyflatname = "F_SKY001"
|
||||||
|
translator = "xlat/strife.txt"
|
||||||
|
defaultbloodcolor = "68 00 00"
|
||||||
|
defaultbloodparticlecolor = "ff 00 00"
|
||||||
|
backpacktype = "AmmoSatchel"
|
||||||
|
statusbar = ""
|
||||||
|
intermissionmusic = "d_slide"
|
||||||
|
}
|
||||||
|
|
||||||
skill baby
|
skill baby
|
||||||
{
|
{
|
||||||
AutoUseHealth
|
AutoUseHealth
|
||||||
|
|
|
@ -1,7 +1,8 @@
|
||||||
// MAPINFO for TNT. Exactly the same as Doom 2, except it
|
// MAPINFO for TNT. Exactly the same as Doom 2, except it
|
||||||
|
|
||||||
// has different map names and cluster messages.
|
// has different map names and cluster messages.
|
||||||
|
|
||||||
|
include "mapinfo/doomcommon.txt"
|
||||||
|
|
||||||
clearepisodes
|
clearepisodes
|
||||||
episode map01
|
episode map01
|
||||||
{
|
{
|
||||||
|
|
10
wadsrc/static/mapinfo/ultdoom.txt
Normal file
10
wadsrc/static/mapinfo/ultdoom.txt
Normal file
|
@ -0,0 +1,10 @@
|
||||||
|
include "mapinfo/doom1.txt"
|
||||||
|
|
||||||
|
gameinfo
|
||||||
|
{
|
||||||
|
creditpage = "CREDIT"
|
||||||
|
chatsound = "misc/chat2"
|
||||||
|
finalepage = "CREDIT", "VICTORY2", "ENDPIC"
|
||||||
|
infopage = "HELP1", "CREDIT"
|
||||||
|
}
|
||||||
|
|
756
zdoom.vcproj
756
zdoom.vcproj
File diff suppressed because it is too large
Load diff
Loading…
Reference in a new issue