diff options
Diffstat (limited to 'src/d_main.c')
-rw-r--r-- | src/d_main.c | 62 |
1 files changed, 31 insertions, 31 deletions
diff --git a/src/d_main.c b/src/d_main.c index 36382fb6..465ed45b 100644 --- a/src/d_main.c +++ b/src/d_main.c @@ -672,9 +672,9 @@ static void InitGameVersion(void) // "ultimate" and "final". // - p = M_CheckParm("-gameversion"); + p = M_CheckParmWithArgs("-gameversion", 1); - if (p > 0) + if (p) { for (i=0; gameversions[i].description != NULL; ++i) { @@ -866,9 +866,9 @@ void D_DoomMain (void) // address. // - p = M_CheckParm("-query"); + p = M_CheckParmWithArgs("-query", 1); - if (p && p < myargc-1) + if (p) { NET_QueryAddress(myargv[p+1]); exit(0); @@ -1019,7 +1019,7 @@ void D_DoomMain (void) // into the main IWAD. Multiple files may be specified. // - p = M_CheckParm("-merge"); + p = M_CheckParmWithArgs("-merge", 1); if (p > 0) { @@ -1045,7 +1045,7 @@ void D_DoomMain (void) // Simulates the behavior of NWT's -merge option. Multiple files // may be specified. - p = M_CheckParm("-nwtmerge"); + p = M_CheckParmWithArgs("-nwtmerge", 1); if (p > 0) { @@ -1070,7 +1070,7 @@ void D_DoomMain (void) // the main IWAD directory. Multiple files may be specified. // - p = M_CheckParm("-af"); + p = M_CheckParmWithArgs("-af", 1); if (p > 0) { @@ -1093,7 +1093,7 @@ void D_DoomMain (void) // into the main IWAD directory. Multiple files may be specified. // - p = M_CheckParm("-as"); + p = M_CheckParmWithArgs("-as", 1); if (p > 0) { @@ -1115,7 +1115,7 @@ void D_DoomMain (void) // Equivalent to "-af <files> -as <files>". // - p = M_CheckParm("-aa"); + p = M_CheckParmWithArgs("-aa", 1); if (p > 0) { @@ -1139,7 +1139,7 @@ void D_DoomMain (void) // Load the specified PWAD files. // - p = M_CheckParm ("-file"); + p = M_CheckParmWithArgs("-file", 1); if (p) { // the parms after p are wadfile/lump names, @@ -1163,7 +1163,7 @@ void D_DoomMain (void) // // convenience hack to allow -wart e m to add a wad file // prepend a tilde to the filename so wadfile will be reloadable - p = M_CheckParm ("-wart"); + p = M_CheckParmWithArgs("-wart", 1); if (p) { myargv[p][4] = 'p'; // big hack, change to -warp @@ -1200,7 +1200,7 @@ void D_DoomMain (void) // Play back the demo named demo.lmp. // - p = M_CheckParm ("-playdemo"); + p = M_CheckParmWithArgs ("-playdemo", 1); if (!p) { @@ -1212,11 +1212,11 @@ void D_DoomMain (void) // Play back the demo named demo.lmp, determining the framerate // of the screen. // - p = M_CheckParm ("-timedemo"); + p = M_CheckParmWithArgs("-timedemo", 1); } - if (p && p < myargc-1) + if (p) { if (!strcasecmp(myargv[p+1] + strlen(myargv[p+1]) - 4, ".lmp")) { @@ -1296,9 +1296,9 @@ void D_DoomMain (void) // 0 disables all monsters. // - p = M_CheckParm ("-skill"); + p = M_CheckParmWithArgs("-skill", 1); - if (p && p < myargc-1) + if (p) { startskill = myargv[p+1][0]-'1'; autostart = true; @@ -1311,9 +1311,9 @@ void D_DoomMain (void) // Start playing on episode n (1-4) // - p = M_CheckParm ("-episode"); + p = M_CheckParmWithArgs("-episode", 1); - if (p && p < myargc-1) + if (p) { startepisode = myargv[p+1][0]-'0'; startmap = 1; @@ -1330,9 +1330,9 @@ void D_DoomMain (void) // For multiplayer games: exit each level after n minutes. // - p = M_CheckParm ("-timer"); + p = M_CheckParmWithArgs("-timer", 1); - if (p && p < myargc-1) + if (p) { timelimit = atoi(myargv[p+1]); } @@ -1346,7 +1346,7 @@ void D_DoomMain (void) p = M_CheckParm ("-avg"); - if (p && p < myargc-1) + if (p) { timelimit = 20; } @@ -1359,9 +1359,9 @@ void D_DoomMain (void) // (Doom 2) // - p = M_CheckParm ("-warp"); + p = M_CheckParmWithArgs("-warp", 1); - if (p && p < myargc-1) + if (p) { if (gamemode == commercial) startmap = atoi (myargv[p+1]); @@ -1405,9 +1405,9 @@ void D_DoomMain (void) // Load the game in slot s. // - p = M_CheckParm ("-loadgame"); + p = M_CheckParmWithArgs("-loadgame", 1); - if (p && p < myargc-1) + if (p) { startloadgame = atoi(myargv[p+1]); } @@ -1507,24 +1507,24 @@ void D_DoomMain (void) // Record a demo named x.lmp. // - p = M_CheckParm ("-record"); + p = M_CheckParmWithArgs("-record", 1); - if (p && p < myargc-1) + if (p) { G_RecordDemo (myargv[p+1]); autostart = true; } - p = M_CheckParm ("-playdemo"); - if (p && p < myargc-1) + p = M_CheckParmWithArgs("-playdemo", 1); + if (p) { singledemo = true; // quit after one demo G_DeferedPlayDemo (demolumpname); D_DoomLoop (); // never returns } - p = M_CheckParm ("-timedemo"); - if (p && p < myargc-1) + p = M_CheckParmWithArgs("-timedemo", 1); + if (p) { G_TimeDemo (demolumpname); D_DoomLoop (); // never returns |