From fc53a73f9b8d93621a6959b3e4171fb8f91337ec Mon Sep 17 00:00:00 2001 From: NepDisk Date: Mon, 13 Oct 2025 11:43:35 -0400 Subject: [PATCH] Kill ->localfile --- src/d_netfil.c | 4 ++-- src/w_wad.c | 20 ++++++++++++-------- src/w_wad.h | 1 - 3 files changed, 14 insertions(+), 11 deletions(-) diff --git a/src/d_netfil.c b/src/d_netfil.c index d34fc4d83..d4aa2b6e8 100644 --- a/src/d_netfil.c +++ b/src/d_netfil.c @@ -167,7 +167,7 @@ UINT8 *PutFileNeeded(UINT16 firstfile) for (; i < numwadfiles; i++) //mainwads+1, otherwise we start on the first mainwad { // If it has only music/sound lumps, don't put it in the list - if (!wadfiles[i]->important || wadfiles[i]->localfile) + if (!wadfiles[i]->important) continue; if (firstfile) @@ -563,7 +563,7 @@ INT32 CL_CheckFiles(void) // CONS_Printf("checking %d of %d / %d of %d?\n", i, fileneedednum, j, numwadfiles); // CONS_Printf("i: %s / j: %s \n", fileneeded[i].filename, wadfiles[j]->filename); - if (j < numwadfiles && (!wadfiles[j]->important || wadfiles[j]->localfile)) + if (j < numwadfiles && !wadfiles[j]->important) { // Unimportant on our side. ++j; diff --git a/src/w_wad.c b/src/w_wad.c index 4d3f0c26e..ba3fff548 100644 --- a/src/w_wad.c +++ b/src/w_wad.c @@ -907,15 +907,20 @@ UINT16 W_InitFile(const char *filename, boolean mainfile, boolean startup, boole if ((handle = W_OpenWadFile(&filename, true)) == NULL) return W_InitFileError(filename, startup); - important = W_VerifyNMUSlumps(filename, startup); - - if (important == -1) + if (local) + important = false; + else { - fclose(handle); - return INT16_MAX; - } + important = W_VerifyNMUSlumps(filename, startup); - important = !important; + if (important == -1) + { + fclose(handle); + return INT16_MAX; + } + + important = !important; + } #ifndef NOFILEHASH // @@ -981,7 +986,6 @@ UINT16 W_InitFile(const char *filename, boolean mainfile, boolean startup, boole fseek(handle, 0, SEEK_END); wadfile->filesize = (unsigned)ftell(handle); wadfile->type = type; - wadfile->localfile = local; // already generated, just copy it over wadfile->hash = filehash; diff --git a/src/w_wad.h b/src/w_wad.h index d654185f1..47ed29c0e 100644 --- a/src/w_wad.h +++ b/src/w_wad.h @@ -131,7 +131,6 @@ struct wadfile_t boolean important; // also network - !W_VerifyNMUSlumps boolean compatmode; - boolean localfile; }; typedef enum wadcompat