From 1be7352f3de77dd7a35d4e57fb6e16a8c216dda7 Mon Sep 17 00:00:00 2001 From: chavonadelal Date: Wed, 18 Sep 2024 20:11:00 +0300 Subject: [PATCH 1/2] Wires ui tooltip localization --- Content.Client/Wires/UI/WiresMenu.cs | 9 ++------- .../Locale/en-US/wires/components/wires-component.ftl | 6 ++++++ 2 files changed, 8 insertions(+), 7 deletions(-) diff --git a/Content.Client/Wires/UI/WiresMenu.cs b/Content.Client/Wires/UI/WiresMenu.cs index eccc548297cd8c..7f581277eaf5bc 100644 --- a/Content.Client/Wires/UI/WiresMenu.cs +++ b/Content.Client/Wires/UI/WiresMenu.cs @@ -584,17 +584,12 @@ public StatusLight(StatusLightData data, IResourceCache resourceCache) private sealed class HelpPopup : Popup { - private const string Text = "Click on the gold contacts with a multitool in hand to pulse their wire.\n" + - "Click on the wires with a pair of wirecutters in hand to cut/mend them.\n\n" + - "The lights at the top show the state of the machine, " + - "messing with wires will probably do stuff to them.\n" + - "Wire layouts are different each round, " + - "but consistent between machines of the same type."; + private readonly string _text = Loc.GetString("wires-menu-help-popup"); public HelpPopup() { var label = new RichTextLabel(); - label.SetMessage(Text); + label.SetMessage(_text); AddChild(new PanelContainer { StyleClasses = {ExamineSystem.StyleClassEntityTooltip}, diff --git a/Resources/Locale/en-US/wires/components/wires-component.ftl b/Resources/Locale/en-US/wires/components/wires-component.ftl index be27c270bb4d58..e98e5c21cab286 100644 --- a/Resources/Locale/en-US/wires/components/wires-component.ftl +++ b/Resources/Locale/en-US/wires/components/wires-component.ftl @@ -10,3 +10,9 @@ wires-component-ui-on-receive-message-cannot-mend-uncut-wire = You can't mend a wires-menu-name-label = Wires wires-menu-dead-beef-text = DEAD-BEEF +wires-menu-help-popup = + Click on the gold contacts with a multitool in hand to pulse their wire. + Click on the wires with a pair of wirecutters in hand to cut/mend them. + + The lights at the top show the state of the machine, messing with wires will probably do stuff to them. + Wire layouts are different each round, but consistent between machines of the same type. From cd795f804d9982d34d830cb81b41a40ebc3adf92 Mon Sep 17 00:00:00 2001 From: chavonadelal Date: Wed, 18 Sep 2024 21:02:52 +0300 Subject: [PATCH 2/2] Corrections after review --- Content.Client/Wires/UI/WiresMenu.cs | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/Content.Client/Wires/UI/WiresMenu.cs b/Content.Client/Wires/UI/WiresMenu.cs index 7f581277eaf5bc..77fc3accceb34a 100644 --- a/Content.Client/Wires/UI/WiresMenu.cs +++ b/Content.Client/Wires/UI/WiresMenu.cs @@ -584,12 +584,10 @@ public StatusLight(StatusLightData data, IResourceCache resourceCache) private sealed class HelpPopup : Popup { - private readonly string _text = Loc.GetString("wires-menu-help-popup"); - public HelpPopup() { var label = new RichTextLabel(); - label.SetMessage(_text); + label.SetMessage(Loc.GetString("wires-menu-help-popup")); AddChild(new PanelContainer { StyleClasses = {ExamineSystem.StyleClassEntityTooltip},