mirror of
https://github.com/Shpoike/Quakespasm.git
synced 2024-11-14 00:50:38 +00:00
717b452da0
git-svn-id: svn://svn.code.sf.net/p/quakespasm/code/trunk/quakespasm@1003 af15c1b1-3010-417e-b628-4374ebc0bcbd
36 lines
1.2 KiB
Diff
36 lines
1.2 KiB
Diff
allow plain files to override files inside a PAK file -- Sander van Dijk
|
|
|
|
might not be compatible with the homedir patch yet -- O.S.
|
|
|
|
Index: Quake/common.c
|
|
===================================================================
|
|
--- Quake/common.c (revision 1003)
|
|
+++ Quake/common.c (working copy)
|
|
@@ -1898,13 +1898,6 @@ static void COM_AddGameDirectory (const
|
|
path_id = com_searchpaths->path_id << 1;
|
|
else path_id = 1U;
|
|
|
|
- // add the directory to the search path
|
|
- search = (searchpath_t *) Z_Malloc(sizeof(searchpath_t));
|
|
- search->path_id = path_id;
|
|
- q_strlcpy (search->filename, com_gamedir, sizeof(search->filename));
|
|
- search->next = com_searchpaths;
|
|
- com_searchpaths = search;
|
|
-
|
|
// add any pak files in the format pak0.pak pak1.pak, ...
|
|
for (i = 0; ; i++)
|
|
{
|
|
@@ -1934,6 +1927,13 @@ static void COM_AddGameDirectory (const
|
|
}
|
|
if (!pak) break;
|
|
}
|
|
+
|
|
+ // add the directory to the search path -- moved here from before the pakX.pak loop -- svdijk
|
|
+ search = (searchpath_t *) Z_Malloc(sizeof(searchpath_t));
|
|
+ search->path_id = path_id;
|
|
+ q_strlcpy (search->filename, com_gamedir, sizeof(search->filename));
|
|
+ search->next = com_searchpaths;
|
|
+ com_searchpaths = search;
|
|
}
|
|
|
|
//==============================================================================
|