mirror of
https://git.code.sf.net/p/quake/quakeforge
synced 2025-01-17 22:50:51 +00:00
fix nq's gamedir handling for the -hipnotic etc shortcuts
This commit is contained in:
parent
31db390df5
commit
b5a960c57b
3 changed files with 7 additions and 17 deletions
|
@ -93,6 +93,5 @@ void QFS_LoadCacheFile (const char *path, struct cache_user_s *cu);
|
|||
void QFS_CreatePath (const char *path);
|
||||
void QFS_Gamedir (const char *dir);
|
||||
void QFS_Init (const char *game);
|
||||
void QFS_CreateGameDirectory (const char *gamename);
|
||||
|
||||
#endif // __quakefs_h
|
||||
|
|
|
@ -1129,14 +1129,6 @@ QFS_Gamedir (const char *dir)
|
|||
Cache_Flush ();
|
||||
}
|
||||
|
||||
void
|
||||
QFS_CreateGameDirectory (const char *gamename)
|
||||
{
|
||||
if (strcmp (fs_userpath->string, "."))
|
||||
QFS_CreatePath (va ("%s/%s/dummy", fs_userpath->string, gamename));
|
||||
QFS_AddGameDirectory (gamename);
|
||||
}
|
||||
|
||||
void
|
||||
QFS_Init (const char *game)
|
||||
{
|
||||
|
@ -1267,7 +1259,7 @@ QFS_WOpen (const char *path, int zip)
|
|||
char mode[4] = "wb\000\000";
|
||||
|
||||
if (zip)
|
||||
mode[2] = bound (1, zip, 9);
|
||||
mode[2] = bound (1, zip, 9) + '0';
|
||||
dsprintf (full_path, "%s/%s", fs_userpath->string, path);
|
||||
QFS_CreatePath (full_path->str);
|
||||
file = Qopen (full_path->str, mode);
|
||||
|
|
|
@ -46,18 +46,17 @@ Game_Init (void)
|
|||
|
||||
// FIXME: make this dependant on QF metadata in the mission packs
|
||||
standard_quake = true;
|
||||
|
||||
if ((i = COM_CheckParm ("-hipnotic"))) {
|
||||
QFS_CreateGameDirectory ("hipnotic");
|
||||
QFS_Gamedir ("hipnotic");
|
||||
standard_quake = false;
|
||||
hipnotic = true;
|
||||
}
|
||||
if ((i = COM_CheckParm ("-rogue"))) {
|
||||
QFS_CreateGameDirectory ("rogue");
|
||||
} else if ((i = COM_CheckParm ("-rogue"))) {
|
||||
QFS_Gamedir ("rogue");
|
||||
standard_quake = false;
|
||||
rogue = true;
|
||||
}
|
||||
if ((i = COM_CheckParm ("-abyss"))) {
|
||||
QFS_CreateGameDirectory ("abyss");
|
||||
} else if ((i = COM_CheckParm ("-abyss"))) {
|
||||
QFS_Gamedir ("abyss");
|
||||
abyss = true;
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue