]> git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/commitdiff
LMS: add a centreprint for the spectate warning 987/head
authorbones_was_here <bones_was_here@xa.org.au>
Sun, 20 Mar 2022 09:02:17 +0000 (19:02 +1000)
committerbones_was_here <bones_was_here@xa.org.au>
Mon, 21 Mar 2022 07:52:05 +0000 (17:52 +1000)
notifications.cfg
qcsrc/common/gamemodes/gamemode/lms/sv_lms.qc
qcsrc/common/notifications/all.inc

index a23eb5539ae13833fdf6b94ee50762af6b30498e..9bfcb335ed2d52d40204aec58df3d04a42d3384b 100644 (file)
@@ -342,7 +342,7 @@ seta notification_INFO_WEAPON_TUBA_SUICIDE "1" "0 = off, 1 = print to console, 2
 seta notification_INFO_WEAPON_VAPORIZER_MURDER "1" "0 = off, 1 = print to console, 2 = print to console and chatbox (if notification_allow_chatboxprint is enabled)"
 seta notification_INFO_WEAPON_VORTEX_MURDER "1" "0 = off, 1 = print to console, 2 = print to console and chatbox (if notification_allow_chatboxprint is enabled)"
 
-// MSG_CENTER notifications (count = 241):
+// MSG_CENTER notifications (count = 242):
 seta notification_CENTER_ALONE "1" "0 = off, 1 = centerprint"
 seta notification_CENTER_ASSAULT_ATTACKING "1" "0 = off, 1 = centerprint"
 seta notification_CENTER_ASSAULT_DEFENDING "1" "0 = off, 1 = centerprint"
@@ -480,6 +480,7 @@ seta notification_CENTER_KEYHUNT_ROUNDSTART "1" "0 = off, 1 = centerprint"
 seta notification_CENTER_KEYHUNT_SCAN "1" "0 = off, 1 = centerprint"
 seta notification_CENTER_KEYHUNT_START "1" "0 = off, 1 = centerprint"
 seta notification_CENTER_LMS_NOLIVES "1" "0 = off, 1 = centerprint"
+seta notification_CENTER_LMS_SPECWARN "1" "0 = off, 1 = centerprint"
 seta notification_CENTER_MISSING_PLAYERS "1" "0 = off, 1 = centerprint"
 seta notification_CENTER_MISSING_TEAMS "1" "0 = off, 1 = centerprint"
 seta notification_CENTER_MOTD "1" "0 = off, 1 = centerprint"
@@ -746,4 +747,4 @@ seta notification_show_sprees_info "3" "Show spree information in MSG_INFO messa
 seta notification_show_sprees_info_newline "1" "Show attacker spree information for MSG_INFO messages on a separate line than the death notification itself"
 seta notification_show_sprees_info_specialonly "1" "Don't show attacker spree information in MSG_INFO messages if it isn't an achievement"
 
-// Notification counts (total = 839): MSG_ANNCE = 80, MSG_INFO = 334, MSG_CENTER = 241, MSG_MULTI = 156, MSG_CHOICE = 28
+// Notification counts (total = 840): MSG_ANNCE = 80, MSG_INFO = 334, MSG_CENTER = 242, MSG_MULTI = 156, MSG_CHOICE = 28
index ffc7768e24cecbbab341ad9f2cc59d8ed605bb0e..6758ea6661ce5e60bc11dcd8c030e0581fff2e9d 100644 (file)
@@ -502,7 +502,8 @@ MUTATOR_HOOKFUNCTION(lms, ClientCommand_Spectate)
                if(player.frags != FRAGS_SPECTATOR && player.frags != FRAGS_PLAYER_OUT_OF_GAME)
                {
                        player.lms_spectate_warning = 1;
-                       sprint(player, "WARNING: you won't be able to enter the game again after spectating in LMS. Use the same command again to spectate anyway.\n");
+                       sprint(player, "^1WARNING:^7 you can't rejoin this match after spectating. Use the same command again to spectate anyway.\n");
+                       Send_Notification(NOTIF_ONE_ONLY, player, MSG_CENTER, CENTER_LMS_SPECWARN);
                }
                return MUT_SPECCMD_RETURN;
        }
index f1b2af8e600164799b48c0922cd20db778d36fcb..51902a5702b1c85e35382a98e4ee682c165482bb 100644 (file)
@@ -703,6 +703,7 @@ string multiteam_info_sprintf(string input, string teamname) { return ((input !=
     MULTITEAM_CENTER(KEYHUNT_START,                     N_ENABLE,    0, 0, "",               CPID_KEYHUNT,           "0 0",  _("^BGYou are starting with the ^TC^TT Key"), "", KEY)
 
     MSG_CENTER_NOTIF(LMS_NOLIVES,                       N_ENABLE,    0, 0, "",               CPID_LMS,               "0 0",  _("^BGYou have no lives left, you must wait until the next match"), "")
+    MSG_CENTER_NOTIF(LMS_SPECWARN,                      N_ENABLE,    0, 0, "",               CPID_LMS,               "0 0",  _("^F4WARNING:^BG you can't rejoin this match after spectating.\nUse the same command again to spectate anyway."), "")
 
     MSG_CENTER_NOTIF(MISSING_TEAMS,                     N_ENABLE,    0, 1, "missing_teams",  CPID_MISSING_TEAMS,     "-1 0", _("^BGWaiting for players to join...\nNeed active players for: %s"), "")
     MSG_CENTER_NOTIF(MISSING_PLAYERS,                   N_ENABLE,    0, 1, "f1",             CPID_MISSING_PLAYERS,   "-1 0", _("^BGWaiting for %s player(s) to join..."), "")