From 47a9de611ad5ebaab1340279644e7cd142ab1b90 Mon Sep 17 00:00:00 2001 From: z411 Date: Sun, 28 May 2023 01:54:13 -0400 Subject: [PATCH] Make variables descriptive --- qcsrc/common/notifications/all.inc | 2 +- qcsrc/server/client.qc | 12 ++++++------ 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/qcsrc/common/notifications/all.inc b/qcsrc/common/notifications/all.inc index 9f2476d4f..52be4acff 100644 --- a/qcsrc/common/notifications/all.inc +++ b/qcsrc/common/notifications/all.inc @@ -388,7 +388,7 @@ string multiteam_info_sprintf(string input, string teamname) { return ((input != MSG_INFO_NOTIF(JOIN_CONNECT, N_CHATCON, 1, 0, "s1", "", "", _("^BG%s^F3 connected"), "") MSG_INFO_NOTIF(JOIN_PLAY, N_CHATCON, 1, 0, "s1", "", "", _("^BG%s^F3 is now playing"), "") MULTITEAM_INFO(JOIN_PLAY_TEAM, N_CHATCON, 1, 0, "s1", "", "", _("^BG%s^F3 is now playing on the ^TC^TT team"), "", NAME) - MULTITEAM_INFO(JOIN_WANTS_TEAM, N_CHATCON, 1, 0, "s1", "", "", _("^BG%s^F3 wants to play on the ^TC^TT team"), "", NAME) + MULTITEAM_INFO(JOIN_WANTS_TEAM, N_CHATCON, 1, 0, "s1", "", "", _("^BG%s^F3 wants to play on the ^TC^TT team"), "", NAME) MSG_INFO_NOTIF(KEEPAWAY_DROPPED, N_CONSOLE, 1, 0, "s1", "s1", "notify_balldropped", _("^BG%s^BG has dropped the ball!"), "") MSG_INFO_NOTIF(KEEPAWAY_PICKUP, N_CONSOLE, 1, 0, "s1", "s1", "notify_ballpickedup", _("^BG%s^BG has picked up the ball!"), "") diff --git a/qcsrc/server/client.qc b/qcsrc/server/client.qc index e487b7cf0..c0d29cfe2 100644 --- a/qcsrc/server/client.qc +++ b/qcsrc/server/client.qc @@ -1979,15 +1979,15 @@ void Join(entity this) TRANSMUTE(Player, this); - entity to_join = SpectatorWantsJoin(this); - if(to_join) + entity queued_join = SpectatorWantsJoin(this); + if(queued_join) { - Join(to_join); + Join(queued_join); this.team_selected = false; // Don't let this player select team } if(!this.team_selected) - if(autocvar_g_campaign || autocvar_g_balance_teams || to_join) + if(autocvar_g_campaign || autocvar_g_balance_teams || queued_join) TeamBalance_JoinBestTeam(this); if(autocvar_g_campaign) @@ -2007,8 +2007,8 @@ void Join(entity this) Send_Notification(NOTIF_ALL, NULL, MSG_INFO, INFO_JOIN_PLAY, this.netname); this.team_selected = false; - if(to_join) - CS(to_join).wants_join = false; + if(queued_join) + CS(queued_join).wants_join = false; } int GetPlayerLimit() -- 2.39.2