From c196eca97f34b1fccf4a2d4d0bf690f47ea0f942 Mon Sep 17 00:00:00 2001 From: ToasterPanic <91223726+ToasterPanic@users.noreply.github.com> Date: Sat, 8 Feb 2025 21:41:46 +0000 Subject: [PATCH] Allow up to 8 players client-side: - Allow 5-8th players to have nametags & score items - Increase size of revive_icons array to 8 (fixes a crash) This does not fix 8 players server-side, but right now the code I have for server-side is spaghetti so I'm not going to burden y'all with that. --- source/client/defs/custom.qc | 2 +- source/client/hud.qc | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/source/client/defs/custom.qc b/source/client/defs/custom.qc index 631b3f7..ece1975 100644 --- a/source/client/defs/custom.qc +++ b/source/client/defs/custom.qc @@ -71,7 +71,7 @@ var struct revive_s { float draw; float timer; float state; -} revive_icons[4]; // MAX_CLIENTS +} revive_icons[8]; // MAX_CLIENTS float weaponframetime; float weapon2frametime; diff --git a/source/client/hud.qc b/source/client/hud.qc index d435702..3c0c437 100644 --- a/source/client/hud.qc +++ b/source/client/hud.qc @@ -1654,7 +1654,7 @@ void() HUD_Scores = Draw_String([g_width/2 + (header_x_pos - getTextWidth("Headshots", scoreboard_text_size)/2), 180], "Headshots", [scoreboard_text_size, scoreboard_text_size], TEXTCOLOR, 1, 0); header_x_pos += header_x_increment; - for (int i = 0; i < 4; i = i + 1) + for (int i = 0; i < 8; i = i + 1) { float player_number = getplayerkeyfloat(i, "client_index"); entity client = findfloat(world, playernum, player_number);