From 14181eee158153ed977a42cb1dc1d7116bd95e35 Mon Sep 17 00:00:00 2001 From: Ozkan Sezer Date: Wed, 30 Jul 2014 09:02:25 +0000 Subject: [PATCH] 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 --- Quake/host_cmd.c | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) diff --git a/Quake/host_cmd.c b/Quake/host_cmd.c index 7a011128..34b3afb3 100644 --- a/Quake/host_cmd.c +++ b/Quake/host_cmd.c @@ -150,7 +150,7 @@ void Host_Game_f (void) 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 { 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]; int i; - i = COM_CheckParm ("-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); - + q_snprintf (dir_string, sizeof(dir_string), "%s/", com_basedir); dir_p = opendir(dir_string); if (dir_p == NULL) return;