From 633208780cb9d495626fdea4b3f5b3af548d81d3 Mon Sep 17 00:00:00 2001 From: bones_was_here Date: Mon, 26 Sep 2022 15:23:07 +1000 Subject: [PATCH] Improve centreprint shown when max player limit blocks joining --- qcsrc/common/notifications/all.inc | 2 +- qcsrc/server/client.qc | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/qcsrc/common/notifications/all.inc b/qcsrc/common/notifications/all.inc index 73c858fcf..440a5bcab 100644 --- a/qcsrc/common/notifications/all.inc +++ b/qcsrc/common/notifications/all.inc @@ -689,7 +689,7 @@ string multiteam_info_sprintf(string input, string teamname) { return ((input != MSG_CENTER_NOTIF(ITEM_WEAPON_UNAVAILABLE, N_ENABLE, 0, 1, "item_wepname", CPID_ITEM, "item_centime 0", _("^F1%s^BG is ^F4not available^BG on this map"), "") MSG_CENTER_NOTIF(JOIN_NOSPAWNS, N_ENABLE, 0, 0, "", CPID_PREVENT_JOIN, "0 0", _("^K1No spawnpoints available!\nHope your team can fix it..."), "") - MSG_CENTER_NOTIF(JOIN_PREVENT, N_ENABLE, 0, 0, "", CPID_PREVENT_JOIN, "0 0", _("^K1You may not join the game at this time.\nThe player limit reached maximum capacity."), "") + MSG_CENTER_NOTIF(JOIN_PREVENT, N_ENABLE, 0, 1, "f1", CPID_PREVENT_JOIN, "0 0", _("^K1You may not join the game at this time.\nThis match is limited to ^F2%s^BG players."), "") MSG_CENTER_NOTIF(KEEPAWAY_DROPPED, N_ENABLE, 1, 0, "s1", CPID_KEEPAWAY, "0 0", _("^BG%s^BG has dropped the ball!"), "") MSG_CENTER_NOTIF(KEEPAWAY_PICKUP, N_ENABLE, 1, 0, "s1", CPID_KEEPAWAY, "0 0", _("^BG%s^BG has picked up the ball!"), "") diff --git a/qcsrc/server/client.qc b/qcsrc/server/client.qc index b60ae7863..17893200d 100644 --- a/qcsrc/server/client.qc +++ b/qcsrc/server/client.qc @@ -2034,7 +2034,7 @@ int nJoinAllowed(entity this, entity ignore) static float msg_time = 0; if(this && !INGAME(this) && ignore && !free_slots && time > msg_time) { - Send_Notification(NOTIF_ONE_ONLY, this, MSG_CENTER, CENTER_JOIN_PREVENT); + Send_Notification(NOTIF_ONE_ONLY, this, MSG_CENTER, CENTER_JOIN_PREVENT, player_limit); msg_time = time + 0.5; } -- 2.39.2