re-diff'ed extra patches under Misc/ so that they apply cleanly.

git-svn-id: svn://svn.code.sf.net/p/quakespasm/code/trunk/quakespasm@1281 af15c1b1-3010-417e-b628-4374ebc0bcbd
This commit is contained in:
Ozkan Sezer 2016-01-16 19:28:04 +00:00
parent b1d6c2b865
commit 55970f514e
2 changed files with 21 additions and 22 deletions

View File

@ -1,14 +1,12 @@
allow plain files to override files inside a PAK file -- Sander van Dijk
allow plain files to override files inside a PAK file -- Sander van Dijk.
Index: Quake/common.c
===================================================================
--- Quake/common.c (revision 1060)
--- Quake/common.c (revision 1280)
+++ Quake/common.c (working copy)
@@ -1900,15 +1900,7 @@ static void COM_AddGameDirectory (const
if (com_searchpaths)
path_id = com_searchpaths->path_id << 1;
@@ -1911,13 +1911,6 @@ static void COM_AddGameDirectory (const
else path_id = 1U;
-
_add_path:
- // add the directory to the search path
- search = (searchpath_t *) Z_Malloc(sizeof(searchpath_t));
@ -20,11 +18,11 @@ Index: Quake/common.c
// add any pak files in the format pak0.pak pak1.pak, ...
for (i = 0; ; i++)
{
@@ -1940,6 +1932,13 @@ _add_path:
@@ -1949,6 +1942,13 @@ _add_path:
if (!pak) break;
}
+ // add the directory to the search path -- moved here from before the pakX.pak loop -- svdijk
+ // 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));

View File

@ -1,9 +1,9 @@
Index: Quake/gl_model.c
===================================================================
--- Quake/gl_model.c (revision 1060)
--- Quake/gl_model.c (revision 1280)
+++ Quake/gl_model.c (working copy)
@@ -401,6 +401,8 @@ void Mod_LoadTextures (lump_t *l)
@@ -404,6 +404,8 @@ void Mod_LoadTextures (lump_t *l)
extern byte *hunk_base;
//johnfitz
@ -12,7 +12,7 @@ Index: Quake/gl_model.c
//johnfitz -- don't return early if no textures; still need to create dummy texture
if (!l->filelen)
{
@@ -452,7 +454,17 @@ void Mod_LoadTextures (lump_t *l)
@@ -465,7 +467,17 @@ void Mod_LoadTextures (lump_t *l)
if (!isDedicated) //no texture uploading for dedicated server
{
if (!q_strncasecmp(tx->name,"sky",3)) //sky texture //also note -- was Q_strncmp, changed to match qbsp
@ -30,7 +30,7 @@ Index: Quake/gl_model.c
else if (tx->name[0] == '*') //warping texture
{
//external textures -- first look in "textures/mapname/" then look in "textures/"
@@ -502,6 +514,52 @@ void Mod_LoadTextures (lump_t *l)
@@ -515,6 +527,52 @@ void Mod_LoadTextures (lump_t *l)
//external textures -- first look in "textures/mapname/" then look in "textures/"
mark = Hunk_LowMark ();
COM_StripExtension (loadmodel->name + 5, mapname, sizeof(mapname));
@ -85,34 +85,35 @@ Index: Quake/gl_model.c
if (!data)
Index: Quake/gl_rmain.c
===================================================================
--- Quake/gl_rmain.c (revision 1060)
--- Quake/gl_rmain.c (revision 1280)
+++ Quake/gl_rmain.c (working copy)
@@ -101,6 +101,7 @@
cvar_t r_nolerp_list = {"r_nolerp_list", "progs/flame.mdl,progs/flame2.mdl,progs/braztall.mdl,progs/brazshrt.mdl,progs/longtrch.mdl,progs/flame_pyre.mdl,progs/v_saw.mdl,progs/v_xfist.mdl,progs/h2stuff/newfire.mdl", CVAR_NONE};
@@ -101,6 +101,8 @@
extern cvar_t r_vfog;
//johnfitz
+
+cvar_t r_externaltexture_fix = {"r_externaltexture_fix","0", CVAR_ARCHIVE}; //mk
cvar_t gl_zfix = {"gl_zfix", "0", CVAR_NONE}; // QuakeSpasm z-fighting fix
Index: Quake/gl_rmisc.c
===================================================================
--- Quake/gl_rmisc.c (revision 1060)
--- Quake/gl_rmisc.c (revision 1280)
+++ Quake/gl_rmisc.c (working copy)
@@ -46,6 +46,7 @@
extern cvar_t r_nolerp_list;
@@ -47,6 +47,7 @@
extern cvar_t r_noshadow_list;
//johnfitz
extern cvar_t gl_zfix; // QuakeSpasm z-fighting fix
+extern cvar_t r_externaltexture_fix; //mk
extern gltexture_t *playertextures[MAX_SCOREBOARD]; //johnfitz
@@ -168,6 +169,7 @@ void R_Init (void)
Cvar_RegisterVariable (&r_nolerp_list);
Cvar_SetCallback (&r_nolerp_list, R_NoLerpList_f);
@@ -231,6 +232,7 @@ void R_Init (void)
Cvar_RegisterVariable (&r_noshadow_list);
Cvar_SetCallback (&r_noshadow_list, R_Model_ExtraFlags_List_f);
//johnfitz
+ Cvar_RegisterVariable (&r_externaltexture_fix); //mk
Cvar_RegisterVariable (&gl_zfix); // QuakeSpasm z-fighting fix
Cvar_RegisterVariable (&r_lavaalpha);