Revert "Only load map lumps that are WADs or have no extension"
This reverts commit 1fb126b4d3.
This commit is contained in:
1 parent
cdc5460fd6
commit
37da18cdcb
2 files changed
+6
-23
No files matched your search
+2
-2
@@ -2840,8 +2840,8 @@ boolean P_SetupLevel(boolean skipprecip, boolean reloadinggamestate)
|
||||
|
||||
// internal game map
|
||||
maplumpname = G_BuildMapName(gamemap);
|
||||
lastloadedmaplumpnum = W_CheckNumForMap(maplumpname);
|
||||
if (lastloadedmaplumpnum == LUMPERROR)
|
||||
lastloadedmaplumpnum = W_CheckNumForName(maplumpname);
|
||||
if (lastloadedmaplumpnum == INT16_MAX)
|
||||
I_Error("Map %s not found.\n", maplumpname);
|
||||
|
||||
curmapvirt = vres_GetMap(lastloadedmaplumpnum);
|
||||
|
||||
+4
-21
@@ -1216,14 +1216,8 @@ lumpnum_t W_CheckNumForMap(const char *name)
|
||||
for (lumpNum = 0; lumpNum < wadfiles[i]->numlumps; lumpNum++)
|
||||
{
|
||||
p = wadfiles[i]->lumpinfo + lumpNum;
|
||||
|
||||
if (p->hash != hash)
|
||||
continue;
|
||||
|
||||
if (strncmp(name, p->name, 8))
|
||||
continue;
|
||||
|
||||
return (i<<16) + lumpNum;
|
||||
if (p->hash == hash && !strncmp(name, p->name, 8))
|
||||
return (i<<16) + lumpNum;
|
||||
}
|
||||
}
|
||||
else if (wadfiles[i]->type == RET_PK3)
|
||||
@@ -1237,19 +1231,8 @@ lumpnum_t W_CheckNumForMap(const char *name)
|
||||
for (; lumpNum < end; lumpNum++)
|
||||
{
|
||||
p = wadfiles[i]->lumpinfo + lumpNum;
|
||||
|
||||
if (p->hash != hash)
|
||||
continue;
|
||||
|
||||
if (strnicmp(name, p->name, 8))
|
||||
continue;
|
||||
|
||||
const char *extension = strrchr(p->fullname, '.');
|
||||
|
||||
if (extension && stricmp(extension, ".wad"))
|
||||
continue;
|
||||
|
||||
return (i<<16) + lumpNum;
|
||||
if (p->hash == hash && !strnicmp(name, p->name, 8))
|
||||
return (i<<16) + lumpNum;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user