From 1eb4dfb13f38f470673b229532f7f7ef30a8411f Mon Sep 17 00:00:00 2001 From: Kara Date: Mon, 8 Aug 2022 16:20:01 -0700 Subject: [PATCH] Rules header cvar + RP server rules header (#10450) --- Content.Client/Info/RulesAndInfoWindow.cs | 2 +- Content.Shared/CCVar/CCVars.cs | 6 ++++++ Resources/Locale/en-US/info/rules.ftl | 3 ++- 3 files changed, 9 insertions(+), 2 deletions(-) diff --git a/Content.Client/Info/RulesAndInfoWindow.cs b/Content.Client/Info/RulesAndInfoWindow.cs index 697f395402..acbe06c565 100644 --- a/Content.Client/Info/RulesAndInfoWindow.cs +++ b/Content.Client/Info/RulesAndInfoWindow.cs @@ -77,7 +77,7 @@ namespace Content.Client.Info public static Control MakeRules(IConfigurationManager cfg, IResourceManager res) { - return MakeSection(Loc.GetString("ui-rules-header"), cfg.GetCVar(CCVars.RulesFile), true, res); + return MakeSection(Loc.GetString(cfg.GetCVar(CCVars.RulesHeader)), cfg.GetCVar(CCVars.RulesFile), true, res); } } } diff --git a/Content.Shared/CCVar/CCVars.cs b/Content.Shared/CCVar/CCVars.cs index f7148a2114..7a24703993 100644 --- a/Content.Shared/CCVar/CCVars.cs +++ b/Content.Shared/CCVar/CCVars.cs @@ -24,6 +24,12 @@ namespace Content.Shared.CCVar public static readonly CVarDef RulesFile = CVarDef.Create("server.rules_file", "Rules.txt", CVar.REPLICATED | CVar.SERVER); + /// + /// A loc string for what should be displayed as the title on the Rules window. + /// + public static readonly CVarDef RulesHeader = + CVarDef.Create("server.rules_header", "ui-rules-header", CVar.REPLICATED | CVar.SERVER); + /* * Ambience */ diff --git a/Resources/Locale/en-US/info/rules.ftl b/Resources/Locale/en-US/info/rules.ftl index 9973bf8728..6bf813c94d 100644 --- a/Resources/Locale/en-US/info/rules.ftl +++ b/Resources/Locale/en-US/info/rules.ftl @@ -1,5 +1,6 @@ # Rules -ui-rules-header = SS14 Official Server Rules +ui-rules-header = Wizard's Den Official Server Rules +ui-rules-header-rp = Wizard's Den Roleplay Official Server Rules ui-rules-accept = I have read and agree to follow the rules ui-rules-wait = The accept button will be enabled after {$time} seconds.