the folder for save/load and default config set to '.'
This commit is contained in:
parent
afc47e5268
commit
470823b640
@ -97,4 +97,4 @@
|
||||
#undef ORIGCODE
|
||||
|
||||
/* Define to the directory where all game files are located */
|
||||
#define FILES_DIR "/mnt"
|
||||
#define FILES_DIR "."
|
||||
|
@ -429,6 +429,8 @@ static char *CheckDirectoryHasIWAD(char *dir, char *iwadname)
|
||||
filename = M_StringJoin(dir, DIR_SEPARATOR_S, iwadname, NULL);
|
||||
}
|
||||
|
||||
printf("Trying IWAD file:%s\n", filename);
|
||||
|
||||
if (M_FileExists(filename))
|
||||
{
|
||||
return filename;
|
||||
@ -611,8 +613,6 @@ static void BuildIWADDirList(void)
|
||||
|
||||
#endif
|
||||
#else
|
||||
AddIWADDir(".");
|
||||
|
||||
AddIWADDir (FILES_DIR);
|
||||
|
||||
// Don't run this function again.
|
||||
@ -735,6 +735,8 @@ char *D_FindIWAD(int mask, GameMission_t *mission)
|
||||
{
|
||||
// Search through the list and look for an IWAD
|
||||
|
||||
printf("-iwad not specified, trying a few iwad names\n");
|
||||
|
||||
result = NULL;
|
||||
|
||||
BuildIWADDirList();
|
||||
|
@ -2042,34 +2042,12 @@ float M_GetFloatVariable(char *name)
|
||||
|
||||
static char *GetDefaultConfigDir(void)
|
||||
{
|
||||
#if !defined(_WIN32) || defined(_WIN32_WCE)
|
||||
|
||||
// Configuration settings are stored in ~/.chocolate-doom/,
|
||||
// except on Windows, where we behave like Vanilla Doom and
|
||||
// save in the current directory.
|
||||
|
||||
char *homedir;
|
||||
char *result;
|
||||
|
||||
// frosted HACK - homedir = getenv("HOME");
|
||||
homedir = "/mnt";
|
||||
|
||||
if (homedir != NULL)
|
||||
{
|
||||
// put all configuration in a config directory off the
|
||||
// homedir
|
||||
|
||||
result = M_StringJoin(homedir, DIR_SEPARATOR_S,
|
||||
"." PACKAGE_TARNAME, DIR_SEPARATOR_S, NULL);
|
||||
char *result = (char *)malloc(2);
|
||||
result[0] = '.';
|
||||
result[1] = '\0';
|
||||
|
||||
return result;
|
||||
}
|
||||
else
|
||||
#endif /* #ifndef _WIN32 */
|
||||
{
|
||||
return strdup(FILES_DIR"/");
|
||||
}
|
||||
}
|
||||
|
||||
//
|
||||
// SetConfigDir:
|
||||
|
Loading…
x
Reference in New Issue
Block a user