- changed the filter name for Doom IWADs

It's "doom.id.doom1/2" instead of "doom.doom1/2" now.
The config file's content will be renamed and for lump filtering a fallback has been added - note that you cannot combine both naming schemes! The old one has to be considered deprecated now.

This also removes the duplicated content necessitated by the old naming scheme.
This commit is contained in:
Christoph Oelckers 2019-04-10 00:15:16 +02:00 committed by Rachael Alexanderson
parent b784bb9679
commit 08c533ae44
10 changed files with 38 additions and 3745 deletions

View file

@ -210,13 +210,23 @@ void FGameConfigFile::DoAutoloadSetup (FIWadManager *iwad_man)
RenameSection("Freedoom2.Autoload", "doom.freedoom.phase2.Autoload"); RenameSection("Freedoom2.Autoload", "doom.freedoom.phase2.Autoload");
RenameSection("Freedoom1.Autoload", "doom.freedoom.phase1.Autoload"); RenameSection("Freedoom1.Autoload", "doom.freedoom.phase1.Autoload");
RenameSection("Freedoom.Autoload", "doom.freedoom.Autoload"); RenameSection("Freedoom.Autoload", "doom.freedoom.Autoload");
RenameSection("DoomBFG.Autoload", "doom.doom1.bfg.Autoload"); RenameSection("DoomBFG.Autoload", "doom.id.doom1.bfg.Autoload");
RenameSection("DoomU.Autoload", "doom.doom1.ultimate.Autoload"); RenameSection("DoomU.Autoload", "doom.id.doom1.ultimate.Autoload");
RenameSection("Doom1.Autoload", "doom.doom1.registered.Autoload"); RenameSection("Doom1.Autoload", "doom.id.doom1.registered.Autoload");
RenameSection("TNT.Autoload", "doom.doom2.tnt.Autoload"); RenameSection("TNT.Autoload", "doom.id.doom2.tnt.Autoload");
RenameSection("Plutonia.Autoload", "doom.doom2.plutonia.Autoload"); RenameSection("Plutonia.Autoload", "doom.id.doom2.plutonia.Autoload");
RenameSection("Doom2BFG.Autoload", "doom.doom2.bfg.Autoload"); RenameSection("Doom2BFG.Autoload", "doom.id.doom2.bfg.Autoload");
RenameSection("Doom2.Autoload", "doom.doom2.commercial.Autoload"); RenameSection("Doom2.Autoload", "doom.id.doom2.commercial.Autoload");
}
else if (last < 218)
{
RenameSection("doom.doom1.bfg.Autoload", "doom.id.doom1.bfg.Autoload");
RenameSection("doom.doom1.ultimate.Autoload", "doom.id.doom1.ultimate.Autoload");
RenameSection("doom.doom1.registered.Autoload", "doom.id.doom1.registered.Autoload");
RenameSection("doom.doom2.tnt.Autoload", "doom.id.doom2.tnt.Autoload");
RenameSection("doom.doom2.plutonia.Autoload", "doom.id.doom2.plutonia.Autoload");
RenameSection("doom.doom2.bfg.Autoload", "doom.id.doom2.bfg.Autoload");
RenameSection("doom.doom2.commercial.Autoload", "doom.id.doom2.commercial.Autoload");
} }
const FString *pAuto; const FString *pAuto;
for (int num = 0; (pAuto = iwad_man->GetAutoname(num)) != NULL; num++) for (int num = 0; (pAuto = iwad_man->GetAutoname(num)) != NULL; num++)

View file

@ -368,6 +368,7 @@ void FResourceFile::PostProcessArchive(void *lumps, size_t lumpsize)
// Entries in archives are sorted alphabetically // Entries in archives are sorted alphabetically
qsort(lumps, NumLumps, lumpsize, lumpcmp); qsort(lumps, NumLumps, lumpsize, lumpcmp);
// Filter out lumps using the same names as the Autoload.* sections // Filter out lumps using the same names as the Autoload.* sections
// in the ini file use. We reduce the maximum lump concidered after // in the ini file use. We reduce the maximum lump concidered after
// each one so that we don't risk refiltering already filtered lumps. // each one so that we don't risk refiltering already filtered lumps.
@ -406,7 +407,17 @@ int FResourceFile::FilterLumps(FString filtername, void *lumps, size_t lumpsize,
return 0; return 0;
} }
filter << "filter/" << filtername << '/'; filter << "filter/" << filtername << '/';
if (FindPrefixRange(filter, lumps, lumpsize, max, start, end))
bool found = FindPrefixRange(filter, lumps, lumpsize, max, start, end);
// Workaround for old Doom filter names.
if (!found && filtername.IndexOf("doom.id.doom") == 0)
{
filter.Substitute("doom.id.doom", "doom.doom");
found = FindPrefixRange(filter, lumps, lumpsize, max, start, end);
}
if (found)
{ {
void *from = (uint8_t *)lumps + start * lumpsize; void *from = (uint8_t *)lumps + start * lumpsize;

View file

@ -65,7 +65,7 @@ const char *GetVersionString();
// Version stored in the ini's [LastRun] section. // Version stored in the ini's [LastRun] section.
// Bump it if you made some configuration change that you want to // Bump it if you made some configuration change that you want to
// be able to migrate in FGameConfigFile::DoGlobalSetup(). // be able to migrate in FGameConfigFile::DoGlobalSetup().
#define LASTRUNVERSION "217" #define LASTRUNVERSION "218"
// Protocol version used in demos. // Protocol version used in demos.
// Bump it if you change existing DEM_ commands or add new ones. // Bump it if you change existing DEM_ commands or add new ones.

View file

@ -1,162 +0,0 @@
BAR1A0, 10, 32, iwad
BAR1B0, 10, 32, iwad
BEXPA0, 10, 32, iwad
BEXPB0, 10, 31, iwad
BEXPC0, 19, 36, iwad
BEXPD0, 27, 49, iwad
BEXPE0, 29, 52, iwad
BOS2I0, 20, 71, iwad
BOS2J0, 26, 62, iwad
BOS2K0, 26, 52, iwad
BOS2L0, 29, 33, iwad
BOS2M0, 30, 29, iwad
BOS2N0, 30, 29, iwad
BOS2O0, 30, 29, iwad
BOSSI0, 20, 72, iwad
BOSSJ0, 26, 63, iwad
BOSSK0, 26, 51, iwad
BOSSL0, 29, 33, iwad
BOSSM0, 30, 29, iwad
BOSSN0, 30, 29, iwad
BOSSO0, 30, 29, iwad
BRS1A0, 13, 8, iwad
BSPIJ0, 50, 54, iwad
BSPIK0, 50, 57, iwad
BSPIL0, 47, 52, iwad
BSPIM0, 45, 44, iwad
BSPIN0, 45, 42, iwad
BSPIO0, 45, 30, iwad
BSPIP0, 45, 28, iwad
CBRAA0, 15, 60, iwad
CEYEA0, 21, 59, iwad
CEYEB0, 21, 58, iwad
CEYEC0, 21, 59, iwad
COL1A0, 16, 51, iwad
COL2A0, 16, 39, iwad
COL3A0, 16, 52, iwad
COL4A0, 17, 39, iwad
COL5A0, 16, 44, iwad
COL5B0, 16, 45, iwad
COL6A0, 17, 47, iwad
COLUA0, 9, 45, iwad
CPOSH0, 20, 61, iwad
CPOSI0, 23, 64, iwad
CPOSJ0, 28, 59, iwad
CPOSK0, 30, 48, iwad
CPOSL0, 31, 34, iwad
CPOSM0, 32, 22, iwad
CPOSN0, 32, 18, iwad
CPOSO0, 26, 59, iwad
CPOSP0, 28, 59, iwad
CPOSQ0, 30, 48, iwad
CPOSR0, 32, 40, iwad
CPOSS0, 32, 31, iwad
CPOST0, 32, 19, iwad
CYBRH0, 60, 108, iwad
CYBRI0, 55, 110, iwad
CYBRJ0, 49, 113, iwad
CYBRK0, 56, 114, iwad
CYBRL0, 62, 121, iwad
CYBRM0, 67, 128, iwad
CYBRN0, 70, 132, iwad
CYBRO0, 69, 132, iwad
CYBRP0, 60, 28, iwad
ELECA0, 19, 125, iwad
FATTO0, 35, 43, iwad
FATTP0, 36, 41, iwad
FATTQ0, 36, 40, iwad
FATTR0, 36, 40, iwad
FATTS0, 36, 40, iwad
FATTT0, 36, 39, iwad
FCANA0, 19, 52, iwad
FCANB0, 19, 52, iwad
FCANC0, 19, 50, iwad
PLAYH0, 16, 50, iwad
PLAYI0, 11, 42, iwad
PLAYJ0, 12, 45, iwad
PLAYK0, 17, 37, iwad
PLAYL0, 27, 14, iwad
PLAYM0, 27, 14, iwad
PLAYN0, 27, 14, iwad
POB1A0, 16, 6, iwad
POB2A0, 14, 3, iwad
POL1A0, 22, 65, iwad
POL2A0, 19, 66, iwad
POL3A0, 19, 42, iwad
POL3B0, 19, 42, iwad
POL4A0, 19, 55, iwad
POL5A0, 27, 8, iwad
POL6A0, 17, 65, iwad
POL6B0, 19, 65, iwad
POSSH0, 19, 55, iwad
POSSL0, 22, 14, iwad
SARGI0, 25, 56, iwad
SARGM0, 33, 43, iwad
SARGN0, 33, 29, iwad
SKELM0, 27, 78, iwad
SKELN0, 38, 69, iwad
SKELO0, 28, 55, iwad
SKELP0, 28, 35, iwad
SKELQ0, 40, 20, iwad
SMITA0, 22, 44, iwad
SPIDJ0, 79, 102, iwad
SPIDK0, 95, 95, iwad
SPIDL0, 94, 88, iwad
SPIDM0, 94, 76, iwad
SPIDN0, 98, 71, iwad
SPIDO0, 101, 68, iwad
SPIDP0, 104, 85, iwad
SPIDQ0, 109, 90, iwad
SPIDR0, 110, 111, iwad
SPIDS0, 98, 35, iwad
SPOSH0, 14, 60, iwad
SPOSL0, 24, 15, iwad
SSWVI0, 18, 54, iwad
SSWVJ0, 15, 44, iwad
SSWVK0, 15, 40, iwad
SSWVL0, 15, 25, iwad
SSWVM0, 24, 13, iwad
SSWVN0, 15, 57, iwad
SSWVO0, 22, 59, iwad
SSWVP0, 25, 58, iwad
TBLUA0, 14, 94, iwad
TBLUB0, 14, 94, iwad
TBLUC0, 14, 94, iwad
TBLUD0, 14, 95, iwad
TGRNA0, 14, 94, iwad
TGRNB0, 14, 89, iwad
TGRNC0, 14, 89, iwad
TGRND0, 14, 95, iwad
TLMPA0, 11, 78, iwad
TLMPB0, 11, 78, iwad
TLMPC0, 11, 78, iwad
TLMPD0, 11, 78, iwad
TLP2A0, 10, 58, iwad
TLP2B0, 10, 58, iwad
TLP2C0, 10, 58, iwad
TLP2D0, 10, 58, iwad
TRE1A0, 25, 67, iwad
TREDA0, 14, 94, iwad
TREDB0, 14, 89, iwad
TREDC0, 14, 89, iwad
TREDD0, 14, 95, iwad
TROOI0, 22, 62, iwad
TROOJ0, 21, 59, iwad
TROOM0, 29, 20, iwad
TROON0, 24, 59, iwad
TROOO0, 20, 61, iwad
TROOP0, 24, 61, iwad
TROOQ0, 24, 61, iwad
TROOR0, 24, 44, iwad
TROOS0, 27, 34, iwad
TROOT0, 27, 31, iwad
TROOU0, 27, 18, iwad
VILER0, 18, 80, iwad
VILES0, 23, 76, iwad
VILET0, 27, 69, iwad
VILEU0, 35, 56, iwad
VILEV0, 34, 45, iwad
VILEW0, 34, 35, iwad
VILEX0, 34, 23, iwad
VILEY0, 34, 20, iwad
VILEZ0, 34, 20, iwad

View file

@ -307,7 +307,7 @@ IWad
IWad IWad
{ {
Name = "DOOM: BFG Edition" Name = "DOOM: BFG Edition"
Autoname = "doom.doom1.bfg" Autoname = "doom.id.doom1.bfg"
Game = "Doom" Game = "Doom"
Config = "Doom" Config = "Doom"
IWADName = "doom.wad", 2 IWADName = "doom.wad", 2
@ -324,7 +324,7 @@ IWad
IWad IWad
{ {
Name = "DOOM: Complete: WadSmoosh" Name = "DOOM: Complete: WadSmoosh"
Autoname = "doom.doom2.wadsmoosh" Autoname = "doom.id.doom2.wadsmoosh"
Game = "Doom" Game = "Doom"
Config = "Doom" Config = "Doom"
Mapinfo = "mapinfo/doom2.txt" Mapinfo = "mapinfo/doom2.txt"
@ -337,7 +337,7 @@ IWad
IWad IWad
{ {
Name = "The Ultimate DOOM" Name = "The Ultimate DOOM"
Autoname = "doom.doom1.ultimate" Autoname = "doom.id.doom1.ultimate"
Game = "Doom" Game = "Doom"
Config = "Doom" Config = "Doom"
IWADName = "doom.wad" IWADName = "doom.wad"
@ -353,7 +353,7 @@ IWad
IWad IWad
{ {
Name = "DOOM Registered" Name = "DOOM Registered"
Autoname = "doom.doom1.registered" Autoname = "doom.id.doom1.registered"
Game = "Doom" Game = "Doom"
Config = "Doom" Config = "Doom"
IWADName = "doom.wad", 1 IWADName = "doom.wad", 1
@ -381,7 +381,7 @@ IWad
IWad IWad
{ {
Name = "Final Doom: TNT - Evilution" Name = "Final Doom: TNT - Evilution"
Autoname = "doom.doom2.tnt" Autoname = "doom.id.doom2.tnt"
Game = "Doom" Game = "Doom"
Config = "Doom" Config = "Doom"
IWADName = "tnt.wad" IWADName = "tnt.wad"
@ -395,7 +395,7 @@ IWad
IWad IWad
{ {
Name = "Final Doom: Plutonia Experiment" Name = "Final Doom: Plutonia Experiment"
Autoname = "doom.doom2.plutonia" Autoname = "doom.id.doom2.plutonia"
Game = "Doom" Game = "Doom"
Config = "Doom" Config = "Doom"
IWADName = "plutonia.wad" IWADName = "plutonia.wad"
@ -409,7 +409,7 @@ IWad
IWad IWad
{ {
Name = "DOOM 2: BFG Edition" Name = "DOOM 2: BFG Edition"
Autoname = "doom.doom2.bfg" Autoname = "doom.id.doom2.bfg"
Game = "Doom" Game = "Doom"
Config = "Doom" Config = "Doom"
IWADName = "doom2.wad" IWADName = "doom2.wad"
@ -425,7 +425,7 @@ IWad
IWad IWad
{ {
Name = "DOOM 2: Hell on Earth" Name = "DOOM 2: Hell on Earth"
Autoname = "doom.doom2.commercial" Autoname = "doom.id.doom2.commercial"
Game = "Doom" Game = "Doom"
Config = "Doom" Config = "Doom"
IWADName = "doom2.wad", 1 IWADName = "doom2.wad", 1

File diff suppressed because it is too large Load diff

File diff suppressed because it is too large Load diff