]> git.rm.cloudns.org Git - xonotic/xonotic-data.pk3dir.git/commitdiff
Add a mutator hook to allow mutators to force drawing of the scoreboard
authorMario <mario.mario@y7mail.com>
Mon, 19 Oct 2020 03:09:36 +0000 (13:09 +1000)
committerMario <mario.mario@y7mail.com>
Mon, 19 Oct 2020 03:09:36 +0000 (13:09 +1000)
qcsrc/client/hud/panel/scoreboard.qc
qcsrc/client/mutators/events.qh

index 7f3c8e5c28a3596d424a39d074d93eff89a96333..7db383a394e6200adb511d3c3560e204869b4f2b 100644 (file)
@@ -1151,7 +1151,7 @@ bool Scoreboard_WouldDraw()
        {
                return true;
        }
-       else if (scoreboard_showscores_force)
+       else if (scoreboard_showscores_force || MUTATOR_CALLHOOK(DrawScoreboard_Force))
                return true;
        return false;
 }
index c606906ab2eb45da744e7ace1b93ff6e1527876b..7115ed4dfba7c6b27233c8b4123ec11928e78ff8 100644 (file)
@@ -172,6 +172,9 @@ MUTATOR_HOOKABLE(DrawCrosshair, EV_NO_ARGS);
 /** Return true to not draw scoreboard */
 MUTATOR_HOOKABLE(DrawScoreboard, EV_NO_ARGS);
 
+/** Return true to force showing of the scoreboard */
+MUTATOR_HOOKABLE(DrawScoreboard_Force, EV_NO_ARGS);
+
 /** Return true to not draw scoreboard while dead */
 MUTATOR_HOOKABLE(DrawDeathScoreboard, EV_NO_ARGS);