]> git.rm.cloudns.org Git - xonotic/xonotic-data.pk3dir.git/commitdiff
remove g_ctf_win_mode
authorRudolf Polzer <divverent@xonotic.org>
Thu, 29 Dec 2011 11:25:54 +0000 (12:25 +0100)
committerRudolf Polzer <divverent@xonotic.org>
Thu, 29 Dec 2011 11:25:54 +0000 (12:25 +0100)
16 files changed:
ctfscoring-ai.cfg
ctfscoring-alien.cfg
ctfscoring-alpha.cfg
ctfscoring-div0.cfg
ctfscoring-nex242.cfg
ctfscoring-z-lowdeposit.cfg
ctfscoring-z.cfg
defaultXonotic.cfg
qcsrc/common/mapinfo.qc
qcsrc/common/mapinfo.qh
qcsrc/server/autocvars.qh
qcsrc/server/ctf.qc
qcsrc/server/defs.qh
qcsrc/server/g_world.qc
qcsrc/server/scores_rules.qc
qcsrc/server/teamplay.qc

index 28ed89dd5f554bb54b01136190854a475400b5de..711373647864160c111a36aec9e7295409e1a6bd 100644 (file)
@@ -1,22 +1,3 @@
-set g_ctf_flagscore_pickup_base                   1
-set g_ctf_flagscore_pickup_dropped_early          0
-set g_ctf_flagscore_pickup_dropped_late           1
-set g_ctf_flagscore_capture                      20
-set g_ctf_flagscore_kill                          2
-set g_ctf_flagpenalty_drop                        0
-set g_ctf_flagpenalty_suicidedrop                 1
-set g_ctf_flagpenalty_returned                    0
-set g_ctf_flagscore_return                        3
-set g_ctf_flagscore_return_rogue                  3
-set g_ctf_flagscore_return_by_killer              5
-set g_ctf_flagscore_return_rogue_by_killer        5
-
-// succeeded capture (pickup capture)            21 (0 for enemy)
-// failed capture (pickup kill drop return)       1 (8 for enemy)
-// failed (shot into void) (pickup kill drop)     1 (2 for enemy)
-// capture retry (kill drop pickup)               0..1 (2 for enemy)
-// suicide, then retake (suicidedrop pickup)     -1 (0 for enemy)
-
 set g_ctf_personalscore_pickup_base                   1
 set g_ctf_personalscore_pickup_dropped_early          0
 set g_ctf_personalscore_pickup_dropped_late           1
index a32ffda130ded00a02ada24b159bf01977b7ad2f..dd5758d495c44bad11517007f4c5b0cf60839229 100644 (file)
@@ -1,21 +1,3 @@
-set g_ctf_flagscore_pickup_base                   1
-set g_ctf_flagscore_pickup_dropped_early          1
-set g_ctf_flagscore_pickup_dropped_late           1
-set g_ctf_flagscore_capture                      30
-set g_ctf_flagscore_kill                          1
-set g_ctf_flagpenalty_drop                        2
-set g_ctf_flagpenalty_suicidedrop                 2
-set g_ctf_flagpenalty_returned                    0
-set g_ctf_flagscore_return                        5
-set g_ctf_flagscore_return_rogue                 10
-set g_ctf_flagscore_return_by_killer              6
-set g_ctf_flagscore_return_rogue_by_killer       11
-// succeeded capture (pickup capture)            31 (0 for enemy)
-// failed capture (pickup kill drop return)      -1 (6 or 7 for enemy)
-// failed (shot into void) (pickup kill drop)     1 (1 for enemy)
-// capture retry (kill drop pickup)              -1 (1 for enemy)
-// suicide, then retake (suicidedrop pickup)     -1 (0 for enemy)
-
 set g_ctf_personalscore_pickup_base                   1
 set g_ctf_personalscore_pickup_dropped_early          1
 set g_ctf_personalscore_pickup_dropped_late           1
index a97bd6e64b5796dde691e1d8ff2f1324200b8f23..c15cee8dab3e26c19333c61b934638374b5c9f0b 100644 (file)
@@ -1,21 +1,3 @@
-set g_ctf_flagscore_pickup_base                   0
-set g_ctf_flagscore_pickup_dropped_early          0
-set g_ctf_flagscore_pickup_dropped_late           0
-set g_ctf_flagscore_capture                      20
-set g_ctf_flagscore_kill                          0
-set g_ctf_flagpenalty_drop                        0
-set g_ctf_flagpenalty_suicidedrop                 0
-set g_ctf_flagpenalty_returned                    0
-set g_ctf_flagscore_return                        5
-set g_ctf_flagscore_return_rogue                 10
-set g_ctf_flagscore_return_by_killer              5
-set g_ctf_flagscore_return_rogue_by_killer       10
-// succeeded capture (pickup capture)            20 (0 for enemy)
-// failed capture (pickup kill drop return)       0 (5 for enemy)
-// failed (shot into void) (pickup kill drop)     0 (0 for enemy)
-// capture retry (kill drop pickup)               0 (0 for enemy)
-// suicide, then retake (suicidedrop pickup)      0 (0 for enemy)
-
 set g_ctf_personalscore_pickup_base                   0
 set g_ctf_personalscore_pickup_dropped_early          0
 set g_ctf_personalscore_pickup_dropped_late           0
index d36d0ad10fe98b24faee9ccbe43382860f4b8585..33c8ab1b72bd9f7d7b7c0da352db959719a74a43 100644 (file)
@@ -1,22 +1,3 @@
-set g_ctf_flagscore_pickup_base                   0
-set g_ctf_flagscore_pickup_dropped_early          1
-set g_ctf_flagscore_pickup_dropped_late           1
-set g_ctf_flagscore_capture                      25
-set g_ctf_flagscore_kill                          3
-set g_ctf_flagpenalty_drop                        2
-set g_ctf_flagpenalty_suicidedrop                 2
-set g_ctf_flagpenalty_returned                    1
-set g_ctf_flagscore_return                        5 // not adjusted as this would suck for team game
-set g_ctf_flagscore_return_rogue                 10
-set g_ctf_flagscore_return_by_killer              5
-set g_ctf_flagscore_return_rogue_by_killer       10
-
-// succeeded capture (pickup capture)            25 (0 for enemy)
-// failed capture (pickup kill drop return)      -3 (8 for enemy)
-// failed (shot into void) (pickup kill drop)    -2 (3 for enemy)
-// capture retry (kill drop pickup)              -1 (3 for enemy)
-// suicide, then retake (suicidedrop pickup)     -1 (0 for enemy)
-
 set g_ctf_personalscore_pickup_base                   0
 set g_ctf_personalscore_pickup_dropped_early          1
 set g_ctf_personalscore_pickup_dropped_late           1
index 193cc183fbb64172f94d58f7893e4f85b4a3669f..861ead4613d165ecef7681adb90dc87f691dc2bb 100644 (file)
@@ -1,21 +1,3 @@
-set g_ctf_flagscore_pickup_base                   1
-set g_ctf_flagscore_pickup_dropped_early          1
-set g_ctf_flagscore_pickup_dropped_late           1
-set g_ctf_flagscore_capture                      20
-set g_ctf_flagscore_kill                          1
-set g_ctf_flagpenalty_drop                        0
-set g_ctf_flagpenalty_suicidedrop                 1
-set g_ctf_flagpenalty_returned                    0
-set g_ctf_flagscore_return                        5
-set g_ctf_flagscore_return_rogue                 10
-set g_ctf_flagscore_return_by_killer              5
-set g_ctf_flagscore_return_rogue_by_killer       10
-// succeeded capture (pickup capture)            21 (0 for enemy)
-// failed capture (pickup kill drop return)       1 (6 for enemy)
-// failed (shot into void) (pickup kill drop)     1 (1 for enemy)
-// capture retry (kill drop pickup)               1 (1 for enemy)
-// suicide, then retake (suicidedrop pickup)      0 (0 for enemy)
-
 set g_ctf_personalscore_pickup_base                   1
 set g_ctf_personalscore_pickup_dropped_early          1
 set g_ctf_personalscore_pickup_dropped_late           1
index 52acece12f1c26bb33c8244ab883586300b53936..c75b30680604af8d657bdeed7cd2e3ac64182325 100644 (file)
@@ -1,5 +1,3 @@
-exec ctfscoring-ai.cfg // fall back to ai's scoring for flag scores, if g_ctf_win_mode is 2, as this system is highly broken in that mode
-
 set g_ctf_personalscore_pickup_base                  -1
 set g_ctf_personalscore_pickup_dropped_early          5
 set g_ctf_personalscore_pickup_dropped_late           9
index bffe0d0561104f474f88b057e096a4e96d7e8f9a..e45bdd93a38b94e353be2573edf4f3090c7e2e24 100644 (file)
@@ -1,5 +1,3 @@
-exec ctfscoring-ai.cfg // fall back to ai's scoring for flag scores, if g_ctf_win_mode is 2, as this system is highly broken in that mode
-
 set g_ctf_personalscore_pickup_base                  -5
 set g_ctf_personalscore_pickup_dropped_early          1
 set g_ctf_personalscore_pickup_dropped_late           5
index a43f289cf3365da86ee7bd21afb6d47747bf0c4e..813163cc8b994f748145c0c9399e752b1595748a 100644 (file)
@@ -616,8 +616,6 @@ seta fraglimit_override -1  "Frag limit overriding the mapinfo specified one (use
 seta leadlimit_override -1     "Lead limit overriding the mapinfo specified one (use 0 to play without limit, and -1 to use the mapinfo's limit)"
 seta capturelimit_override -1  "Capture limit overriding the mapinfo specified one (use 0 to play without limit, and -1 to use the mapinfo's limit)"
 seta captureleadlimit_override -1      "Capture llead imit overriding the mapinfo specified one (use 0 to play without limit, and -1 to use the mapinfo's limit)"
-seta g_ctf_capture_limit -1    "CTF capture limit overriding the mapinfo specified one (use 0 to play without limit, and -1 to use the mapinfo's limit)"
-seta g_ctf_capture_leadlimit -1        "CTF capture lead limit overriding the mapinfo specified one (use 0 to play without limit, and -1 to use the mapinfo's limit)"
 seta g_arena_point_limit -1    "Arena point limit overriding the mapinfo specified one (use 0 to play without limit, and -1 to use the mapinfo's limit)"
 seta g_arena_point_leadlimit -1        "Arena point lead limit overriding the mapinfo specified one (use 0 to play without limit, and -1 to use the mapinfo's limit)"
 seta g_domination_point_limit -1       "Domination point limit overriding the mapinfo specified one (use 0 to play without limit, and -1 to use the mapinfo's limit)"
@@ -630,7 +628,6 @@ seta g_race_laps_limit -1   "Race laps limit overriding the mapinfo specified one
 seta g_nexball_goallimit -1 "Nexball goal limit overriding the mapinfo specified one (use 0 to play without limit, and -1 to use the mapinfo's limit)"
 seta g_nexball_goalleadlimit -1 "Nexball goal lead limit overriding the mapinfo specified one (use 0 to play without limit, and -1 to use the mapinfo's limit)"
 
-seta g_ctf_win_mode 0  "0: captures only, 1: captures, then points, 2: points only"
 seta g_ctf_ignore_frags 0      "1: regular frags give no points"
 
 set g_freezetag 0 "Freeze Tag: Freeze the opposing team(s) to win, unfreeze teammates by standing next to them"
index 923316652c34189247d927d52e4103840404b11b..1b32c9d1d5a076c3825f5ea9900522282f7abd40 100644 (file)
@@ -472,8 +472,7 @@ void _MapInfo_Map_ApplyGametype(string s, float pWantedType, float pThisType, fl
        {
                sa = car(s);
                if(sa != "")
-                       if(cvar("g_ctf_win_mode") < 2)
-                               cvar_set("fraglimit", sa);
+                       cvar_set("fraglimit", sa);
                s = cdr(s);
        }
 
@@ -547,7 +546,6 @@ void _MapInfo_Map_ApplyGametypeEx(string s, float pWantedType, float pThisType)
        string sa, k, v;
        float p;
        string fraglimit_normal;
-       string fraglimit_caps;
        string fraglimit_teams;
 
        MapInfo_Map_supportedGametypes |= pThisType;
@@ -565,7 +563,6 @@ void _MapInfo_Map_ApplyGametypeEx(string s, float pWantedType, float pThisType)
        cvar_set("g_race_qualifying_timelimit", cvar_defstring("g_race_qualifying_timelimit"));
 
        fraglimit_normal = string_null;
-       fraglimit_caps = string_null;
        fraglimit_teams = string_null;
 
        s = strcat(_MapInfo_GetDefaultEx(pWantedType), " ", s);
@@ -597,14 +594,10 @@ void _MapInfo_Map_ApplyGametypeEx(string s, float pWantedType, float pThisType)
                {
                        cvar_set("leadlimit", v);
                }
-               else if(k == "pointlimit" || k == "fraglimit" || k == "lives" || k == "laplimit")
+               else if(k == "pointlimit" || k == "fraglimit" || k == "lives" || k == "laplimit" || k == "caplimit")
                {
                        fraglimit_normal = v;
                }
-               else if(k == "caplimit")
-               {
-                       fraglimit_caps = v;
-               }
                else if(k == "teampointlimit" || k == "teamlaplimit")
                {
                        fraglimit_teams = v;
@@ -629,12 +622,7 @@ void _MapInfo_Map_ApplyGametypeEx(string s, float pWantedType, float pThisType)
                }
        }
 
-       if(pWantedType == MAPINFO_TYPE_CTF && cvar("g_ctf_win_mode") < 2)
-       {
-               if(fraglimit_caps)
-                       cvar_set("fraglimit", fraglimit_caps);
-       }
-       else if(pWantedType == MAPINFO_TYPE_RACE && cvar("g_race_teams") >= 2)
+       if(pWantedType == MAPINFO_TYPE_RACE && cvar("g_race_teams") >= 2)
        {
                if(fraglimit_teams)
                        cvar_set("fraglimit", fraglimit_teams);
index 1fc8bb59f6d6b85fd237181bdd54da371ea32f2a..e47a28369f783589cfae824b6b603a61e0b91a03 100644 (file)
@@ -54,7 +54,7 @@ REGISTER_GAMETYPE(_("Race CTS"),cts,g_cts,CTS,"timelimit=20 skill=-1")
 REGISTER_GAMETYPE(_("Team Deathmatch"),tdm,g_tdm,TEAM_DEATHMATCH,"timelimit=20 pointlimit=50 teams=2 leadlimit=0")
 #define g_tdm IS_GAMETYPE(TEAM_DEATHMATCH)
 
-REGISTER_GAMETYPE(_("Capture the Flag"),ctf,g_ctf,CTF,"timelimit=20 pointlimit=300 caplimit=10 leadlimit=0")
+REGISTER_GAMETYPE(_("Capture the Flag"),ctf,g_ctf,CTF,"timelimit=20 caplimit=10 leadlimit=0")
 #define g_ctf IS_GAMETYPE(CTF)
 
 REGISTER_GAMETYPE(_("Clan Arena"),ca,g_ca,CA,"timelimit=20 pointlimit=10 leadlimit=0")
index 9cd1fa9e8b4f0334cd343a37a4eb2d5014de5670..d41840250eb64754796e2591af4aa2a848d86164 100644 (file)
@@ -757,8 +757,6 @@ float autocvar_g_chat_flood_spl_tell;
 float autocvar_g_chat_nospectators;
 float autocvar_g_chat_teamcolors;
 float autocvar_g_ctf_captimerecord_always;
-float autocvar_g_ctf_capture_leadlimit;
-float autocvar_g_ctf_capture_limit;
 float autocvar_g_ctf_dynamiclights;
 string autocvar_g_ctf_flag_blue_model;
 float autocvar_g_ctf_flag_blue_skin;
index 6f7198c2a9f225e803fe7f63d5faa557063262a6..f5835377d982ea2ded4998baf629d3711883b787 100644 (file)
@@ -135,10 +135,7 @@ void ctf_flag_spawnstuff()
 
 float ctf_score_value(string parameter)
 {
-       if(g_ctf_win_mode != 2)
-               return cvar(strcat("g_ctf_personal", parameter));
-       else
-               return cvar(strcat("g_ctf_flag", parameter));
+       return cvar(strcat("g_ctf_personal", parameter));
 }
 
 void FakeTimeLimit(entity e, float t)
@@ -1012,11 +1009,6 @@ void ctf_init()
        captureshield_min_negscore = autocvar_g_ctf_shield_min_negscore;
        captureshield_max_ratio = autocvar_g_ctf_shield_max_ratio;
        captureshield_force = autocvar_g_ctf_shield_force;
-
-
-//#NO AUTOCVARS START
-       g_ctf_win_mode = cvar("g_ctf_win_mode");
-//#NO AUTOCVARS END
 }
 
 void ctf_setstatus2(entity flag, float shift)
index bea9fddb3616f6f0868c11f607f26f4d30d6860c..4b2684c510a730cbaf0ecc9ce6cdab141b9b8779 100644 (file)
@@ -22,7 +22,6 @@ float g_cloaked, g_footsteps, g_jump_grunt, g_grappling_hook, g_midair, g_minsta
 float g_warmup_limit;
 float g_warmup_allguns;
 float g_warmup_allow_timeout;
-float g_ctf_win_mode;
 float g_ctf_ignore_frags;
 float g_ctf_reverse;
 float g_race_qualifying;
index f115434a2791ac70a028b295400eeab2071e2d0f..e4ed89a85a2e7fb347dfbd3c153e6b287008de4a 100644 (file)
@@ -372,7 +372,6 @@ void cvar_changes_init()
                BADCVAR("g_balance_kill_delay");
                BADCVAR("g_ca_point_leadlimit");
                BADCVAR("g_ctf_captimerecord_always");
-               BADCVAR("g_ctf_capture_leadlimit");
                BADCVAR("g_ctf_flag_capture_effects");
                BADCVAR("g_ctf_flag_glowtrails");
                BADCVAR("g_ctf_flag_pickup_effects");
@@ -427,9 +426,7 @@ void cvar_changes_init()
                BADCVAR("g_balance_teams_force");
                BADCVAR("g_ban_sync_trusted_servers");
                BADCVAR("g_ban_sync_uri");
-               BADCVAR("g_ctf_capture_limit");
                BADCVAR("g_ctf_ignore_frags");
-               BADCVAR("g_ctf_win_mode");
                BADCVAR("g_domination_point_limit");
                BADCVAR("g_friendlyfire");
                BADCVAR("g_fullbrightitems");
index eb7205e9c3859bf5d3c2977d8bde069bd31993d7..806e2450792d356ff0c1298bcbdc53fefd614780 100644 (file)
@@ -53,27 +53,9 @@ void ScoreRules_generic()
 #define SP_CTF_RETURNS 8
 void ScoreRules_ctf()
 {
-       float sp_score, sp_caps;
-       sp_score = sp_caps = 0;
-       switch(g_ctf_win_mode)
-       {
-               case 0: // caps only
-                       sp_caps = SFL_SORT_PRIO_PRIMARY;
-                       break;
-               case 1: // caps, then score
-                       sp_caps = SFL_SORT_PRIO_PRIMARY;
-                       sp_score = SFL_SORT_PRIO_SECONDARY;
-                       break;
-               case 2: // score only
-               default:
-                       sp_caps = SFL_SORT_PRIO_SECONDARY; // looks better ;)
-                       sp_score = SFL_SORT_PRIO_PRIMARY;
-                       break;
-       }
-
        CheckAllowedTeams(world);
-       ScoreRules_basics(2 + (c3>=0), SFL_SORT_PRIO_PRIMARY, sp_score, TRUE); // NOTE this assumes that the rogue team is team 3
-       ScoreInfo_SetLabel_TeamScore  (ST_CTF_CAPS,     "caps",      sp_caps);
+       ScoreRules_basics(2 + (c3>=0), SFL_SORT_PRIO_PRIMARY, 0, TRUE); // NOTE this assumes that the rogue team is team 3
+       ScoreInfo_SetLabel_TeamScore  (ST_CTF_CAPS,     "caps",      SFL_SORT_PRIO_PRIMARY);
        ScoreInfo_SetLabel_PlayerScore(SP_CTF_CAPS,     "caps",      SFL_SORT_PRIO_SECONDARY);
        ScoreInfo_SetLabel_PlayerScore(SP_CTF_PICKUPS,  "pickups",   0);
        ScoreInfo_SetLabel_PlayerScore(SP_CTF_FCKILLS,  "fckills",   0);
index 52bab5d9d0669550cec63f053a2492698d22136a..f0ce8fd142ec4027b10c524db8b97297a90a8968 100644 (file)
@@ -159,16 +159,8 @@ void InitGameplayMode()
        {
                ActivateTeamplay();
                g_ctf_ignore_frags = autocvar_g_ctf_ignore_frags;
-               if(g_ctf_win_mode == 2)
-               {
-                       fraglimit_override = autocvar_g_ctf_capture_limit;
-                       leadlimit_override = autocvar_g_ctf_capture_leadlimit;
-               }
-               else
-               {
-                       fraglimit_override = autocvar_capturelimit_override;
-                       leadlimit_override = autocvar_captureleadlimit_override;
-               }
+               fraglimit_override = autocvar_capturelimit_override;
+               leadlimit_override = autocvar_captureleadlimit_override;
                ctf_init();
                have_team_spawns = -1; // request team spawns
        }