X-Git-Url: https://git.xonotic.org/?p=xonotic%2Fgmqcc.git;a=blobdiff_plain;f=main.c;h=41828c7d3ff68c4be14c2e61b2e69b52a0ceecb6;hp=156a3f0c1af5c81c4c72d7ac70dc64087ea5c29c;hb=1ad849d9391c55c85bb51b6a07237aa2185123af;hpb=9cc4fe1ed246e3c37af7cbd7245b0b413372f3b9 diff --git a/main.c b/main.c index 156a3f0..41828c7 100644 --- a/main.c +++ b/main.c @@ -1,5 +1,5 @@ /* - * Copyright (C) 2012, 2013, 2014 + * Copyright (C) 2012, 2013, 2014, 2015 * Dale Weiler * Wolfgang Bumiller * @@ -85,6 +85,7 @@ static int usage(void) { " -Ono- disable specific optimization\n" " -Ohelp list optimizations\n"); con_out(" -force-crc=num force a specific checksum into the header\n"); + con_out(" -state-fps=num emulate OP_STATE with the specified FPS\n"); con_out(" -coverage add coverage support\n"); return -1; } @@ -217,6 +218,11 @@ static bool options_parse(int argc, char **argv) { OPTS_OPTION_U16 (OPTION_FORCED_CRC) = strtol(argarg, NULL, 0); continue; } + if (options_long_gcc("state-fps", &argc, &argv, &argarg)) { + OPTS_OPTION_U32(OPTION_STATE_FPS) = strtol(argarg, NULL, 0); + opts_set(opts.flags, EMULATE_STATE, true); + continue; + } if (options_long_gcc("redirout", &argc, &argv, &redirout)) { con_change(redirout, redirerr); continue; @@ -492,14 +498,6 @@ static bool options_parse(int argc, char **argv) { OPTS_OPTION_BOOL(OPTION_QUIET) = true; break; } - else if (!strcmp(argv[0]+2, "correct")) { - OPTS_OPTION_BOOL(OPTION_CORRECTION) = true; - break; - } - else if (!strcmp(argv[0]+2, "no-correct")) { - OPTS_OPTION_BOOL(OPTION_CORRECTION) = false; - break; - } else if (!strcmp(argv[0]+2, "add-info")) { OPTS_OPTION_BOOL(OPTION_ADD_INFO) = true; break; @@ -793,7 +791,6 @@ cleanup: mem_d((void*)operators); lex_cleanup(); - stat_info(); if (!retval && compile_errors) retval = 1;