mirror of
https://github.com/Shpoike/Quakespasm.git
synced 2024-11-10 15:31:39 +00:00
Host_Game_f: fix broken behavion if -gamedir is specified. (use com_basedir, not host_parms->basedir)
Modlist_Init: no need for -basedir check, just use com_basedir git-svn-id: svn://svn.code.sf.net/p/quakespasm/code/trunk/quakespasm@941 af15c1b1-3010-417e-b628-4374ebc0bcbd
This commit is contained in:
parent
4e8c42b050
commit
14181eee15
1 changed files with 2 additions and 7 deletions
|
@ -150,7 +150,7 @@ void Host_Game_f (void)
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
q_strlcpy (pakfile, va("%s/%s", host_parms->basedir, p), sizeof(pakfile));
|
q_strlcpy (pakfile, va("%s/%s", com_basedir, p), sizeof(pakfile));
|
||||||
if (!q_strcasecmp(pakfile, com_gamedir)) //no change
|
if (!q_strcasecmp(pakfile, com_gamedir)) //no change
|
||||||
{
|
{
|
||||||
Con_Printf("\"game\" is already \"%s\"\n", COM_SkipPath(com_gamedir));
|
Con_Printf("\"game\" is already \"%s\"\n", COM_SkipPath(com_gamedir));
|
||||||
|
@ -407,12 +407,7 @@ void Modlist_Init (void)
|
||||||
char dir_string[MAX_OSPATH], mod_dir_string[MAX_OSPATH];
|
char dir_string[MAX_OSPATH], mod_dir_string[MAX_OSPATH];
|
||||||
int i;
|
int i;
|
||||||
|
|
||||||
i = COM_CheckParm ("-basedir");
|
q_snprintf (dir_string, sizeof(dir_string), "%s/", com_basedir);
|
||||||
if (i && i < com_argc-1)
|
|
||||||
q_snprintf (dir_string, sizeof(dir_string), "%s/", com_argv[i+1]);
|
|
||||||
else
|
|
||||||
q_snprintf (dir_string, sizeof(dir_string), "%s/", host_parms->basedir);
|
|
||||||
|
|
||||||
dir_p = opendir(dir_string);
|
dir_p = opendir(dir_string);
|
||||||
if (dir_p == NULL)
|
if (dir_p == NULL)
|
||||||
return;
|
return;
|
||||||
|
|
Loading…
Reference in a new issue