Skip to content

Commit

Permalink
Merge pull request #233 from Gedevan-Aleksizde/localization-fix
Browse files Browse the repository at this point in the history
Localization fix
  • Loading branch information
bennyz authored Oct 6, 2023
2 parents 6f1538f + 8fc59f5 commit 44724d3
Show file tree
Hide file tree
Showing 4 changed files with 14 additions and 6 deletions.
5 changes: 3 additions & 2 deletions src/Bannerlord.Diplomacy/SubModule.cs
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@
using TaleWorlds.Core;
using TaleWorlds.Library;
using TaleWorlds.MountAndBlade;
using TaleWorlds.Localization;

namespace Diplomacy
{
Expand All @@ -28,7 +29,7 @@ public sealed class SubModule : MBSubModuleBase
public static readonly string Version = $"v{typeof(SubModule).Assembly.GetName().Version.ToString(3)}";

public static readonly string Name = typeof(SubModule).Namespace;
public static readonly string DisplayName = Name;
public static readonly string DisplayName = new TextObject($"{{=MYz8nKqq}}{Name}").ToString();
public static readonly string MainHarmonyDomain = "bannerlord." + Name.ToLower();
public static readonly string CampaignHarmonyDomain = MainHarmonyDomain + ".campaign";
public static readonly string WidgetHarmonyDomain = MainHarmonyDomain + ".widgets";
Expand Down Expand Up @@ -74,7 +75,7 @@ protected override void OnBeforeInitialModuleScreenSetAsRoot()
_hasLoaded = true;
Log.LogInformation($"Loaded {Name} {Version}!");

InformationManager.DisplayMessage(new InformationMessage($"Loaded {DisplayName}", StdTextColor));
InformationManager.DisplayMessage(new InformationMessage(new TextObject($"{{=hPERH3u4}}Loaded {{NAME}}").SetTextVariable("NAME", DisplayName).ToString(), StdTextColor));
}
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@
<string id="6kNmdLxZ" text="Faction Creation Influence Cost" />
<string id="EwbXg3va" text="The influence cost of starting a faction. Default value is 100." />
<string id="7wK0mmw1" text="Faction Tendency" />
<string id="7wK0mmw1" text="Score modifier affecting the tendency of clans to create or join factions. Increasing the modifier increases faction participation. Default value is 0." />
<string id="aqvIdG7w" text="Score modifier affecting the tendency of clans to create or join factions. Increasing the modifier increases faction participation. Default value is 0." />

</strings>
</base>
Original file line number Diff line number Diff line change
@@ -1,2 +1,8 @@
<?xml version="1.0" encoding="utf-8"?>
<LanguageData id="English" />
<LanguageData id="English">
<LanguageFile xml_path="civil_war_strings_xml.xml" />
<LanguageFile xml_path="faction_names_xml.xml" />
<LanguageFile xml_path="help_strings_xml.xml" />
<LanguageFile xml_path="std_module_strings_xml.xml" />
<LanguageFile xml_path="war_exhaustion_strings.xml" />
</LanguageData>
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@
<string id="DrnXprup" text="You have been at war too recently to consider an alliance. It has only been {ELAPSED_DAYS} days out of a required {REQUIRED_DAYS} days." />
<string id="KHJyWj9H" text="Cannot be in an alliance." />
<string id="UQZmdLzc" text="Cannot be at war." />
<string id="PdN5g5ub" text="Alliance Formed" />
<string id="qIa19an4" text="Alliance Formed" />
<string id="3pbwc8sh" text="Alliance Proposal"/>
<string id="QbOqatd7" text="{KINGDOM} is proposing an alliance with {PLAYER_KINGDOM}." />

Expand Down Expand Up @@ -101,7 +101,7 @@
<string id="gyLjlpJB" text="{KINGDOM} is proposing a non-aggression pact with {PLAYER_KINGDOM}."/>

<string id="9pY0NQrk" text="Form Pact"/>
<string id="9zlQNtlX" text="Form a non-aggression pact lasting {PACT_DURATION_DAYS} days."/>
<string id="9zlQNtlX" text="Form a non-aggression pact lasting {DAYS} days."/>

<string id="1occw3EF" text="Stats"/>
<string id="OvbY5qxL" text="Overview"/>
Expand Down Expand Up @@ -136,6 +136,7 @@
<string id="qbLPBlIv" text="Calradia grows wary of the inexorable expansion of the {EXPANSIONIST_KINGDOM}. A coalition led by the {COALITION_KINGDOM} has been formed to fight them!"/>

<string id="vB3RrMNf" text="The {KINGDOM} has formed a non-aggression pact with the {OTHER_KINGDOM}." />
<string id="PdN5g5ub" text="{KINGDOM} has formed an alliance with {OTHER_KINGDOM}!">
<string id="5r6fsHgm" text="Current Score"/>
<string id="XIBUWDlT" text="Required Score"/>

Expand Down

0 comments on commit 44724d3

Please sign in to comment.