]> git.rm.cloudns.org Git - xonotic/xonotic-data.pk3dir.git/commitdiff
Fix cloaked mode not getting forced enabled in CTS
authorMario <zacjardine@y7mail.com>
Thu, 13 Nov 2014 14:28:33 +0000 (01:28 +1100)
committerMario <zacjardine@y7mail.com>
Thu, 13 Nov 2014 14:28:33 +0000 (01:28 +1100)
qcsrc/server/mutators/gamemode_cts.qc

index ef4d53dad061c34511c4e8fc58e0715b755aa26a..9be1dc542c8e5ce602e56bda43a1a7b2100353db 100644 (file)
@@ -266,10 +266,15 @@ MUTATOR_HOOKFUNCTION(cts_ForbidClearPlayerScore)
        return TRUE; // in CTS, you don't lose score by observing
 }
 
-void cts_Initialize()
+MUTATOR_HOOKFUNCTION(cts_SetMods)
 {
        g_cloaked = 1; // always enable cloak in CTS
 
+       return FALSE;
+}
+
+void cts_Initialize()
+{
        cts_ScoreRules();
 }
 
@@ -289,6 +294,7 @@ MUTATOR_DEFINITION(gamemode_cts)
        MUTATOR_HOOK(FilterItem, cts_FilterItem, CBC_ORDER_ANY);
        MUTATOR_HOOK(PlayerDamage_Calculate, cts_PlayerDamage, CBC_ORDER_ANY);
        MUTATOR_HOOK(ForbidPlayerScore_Clear, cts_ForbidClearPlayerScore, CBC_ORDER_ANY);
+       MUTATOR_HOOK(SetModname, cts_SetMods, CBC_ORDER_ANY);
 
        MUTATOR_ONADD
        {