From: otta8634 Date: Thu, 12 Sep 2024 04:16:45 +0000 (+0800) Subject: Partly reduce CCR usage elsewhere X-Git-Url: https://git.rm.cloudns.org/?a=commitdiff_plain;h=fcc84e806df97292da4f2844b2a2582c50b53185;p=xonotic%2Fxonotic-data.pk3dir.git Partly reduce CCR usage elsewhere --- diff --git a/qcsrc/client/main.qc b/qcsrc/client/main.qc index 9cf0185ed..c584a2892 100644 --- a/qcsrc/client/main.qc +++ b/qcsrc/client/main.qc @@ -1424,9 +1424,9 @@ bool net_handle_ServerWelcome() // (that client doesn't know) by replacing the keyword _LEVEL_DESC string key = getcommandkey(_("jump"), "+jump"); string msg = strcat( - CCR("^F1"), sprintf(_("Level %d:"), campaign_level), - sprintf(CCR(" ^BG%s\n\n"), "_LEVEL_DESC"), - sprintf(CCR(_("^BGPress ^F2%s^BG to enter the game")), key)); + CCR_F1, sprintf(_("Level %d:"), campaign_level), " ", + CCR_BG, sprintf("%s\n\n", "_LEVEL_DESC"), + CCR_BG, sprintf(CCR(_("Press ^F2%s^BG to enter the game")), key)); msg = MakeConsoleSafe(strreplace("\n", "\\n", msg)); string welcomedialog_args = strcat("CAMPAIGN ", itos(campaign_level), " \"", msg, "\""); diff --git a/qcsrc/common/notifications/all.qh b/qcsrc/common/notifications/all.qh index e56658a68..b20c607a4 100644 --- a/qcsrc/common/notifications/all.qh +++ b/qcsrc/common/notifications/all.qh @@ -438,7 +438,7 @@ string BUFF_NAME(int i); ARG_CASE(ARG_CS_SV_HA, "f1race_time", TIME_ENCODED_TOSTRING(f1, true)) \ ARG_CASE(ARG_CS_SV_HA, "f2race_time", TIME_ENCODED_TOSTRING(f2, true)) \ ARG_CASE(ARG_CS_SV_HA, "f3race_time", TIME_ENCODED_TOSTRING(f3, true)) \ - ARG_CASE(ARG_CS_SV, "race_col", CCR((f1 == 1) ? "^F1" : "^F2")) \ + ARG_CASE(ARG_CS_SV, "race_col", ((f1 == 1) ? CCR_F1 : CCR_F2)) \ ARG_CASE(ARG_CS_SV, "race_diff", ((f2 > f3) ? sprintf("^1[+%s]", TIME_ENCODED_TOSTRING(f2 - f3, true)) : sprintf("^2[-%s]", TIME_ENCODED_TOSTRING(f3 - f2, true)))) \ ARG_CASE(ARG_CS, "missing_teams", notif_arg_missing_teams(f1)) \ ARG_CASE(ARG_CS, "pass_key", getcommandkey(_("drop flag"), "+use")) \