]> git.rm.cloudns.org Git - xonotic/xonotic-data.pk3dir.git/commitdiff
Scoreboard UI: fix not being able to switch to the Rankings panel
authorterencehill <piuntn@gmail.com>
Tue, 7 Jun 2022 21:41:29 +0000 (23:41 +0200)
committerterencehill <piuntn@gmail.com>
Tue, 7 Jun 2022 21:41:29 +0000 (23:41 +0200)
qcsrc/client/hud/panel/scoreboard.qc

index dfab7d61b7c3fae437bd9677357a26be1ba648aa..531e0c35618f04db70303e5bef22dad11326e593 100644 (file)
@@ -277,8 +277,8 @@ float HUD_Scoreboard_InputEvent(float bInputType, float nPrimary, float nSeconda
                ++scoreboard_selected_panel;
                if (scoreboard_selected_panel == SB_PANEL_RANKINGS && !rankings_cnt)
                        ++scoreboard_selected_panel;
-               if (scoreboard_selected_panel >= SB_PANEL_MAX)
-                       scoreboard_selected_panel = 1;
+               if (scoreboard_selected_panel > SB_PANEL_MAX)
+                       scoreboard_selected_panel = SB_PANEL_FIRST;
 
                scoreboard_selected_panel_time = time;
        }