Skip to content

Commit

Permalink
Move localisation to existing file to avoid silly new class
Browse files Browse the repository at this point in the history
  • Loading branch information
peppy committed May 11, 2024
1 parent da09637 commit ac7598c
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 21 deletions.
19 changes: 0 additions & 19 deletions osu.Game/Localisation/FooterButtonModsV2Strings.cs

This file was deleted.

8 changes: 7 additions & 1 deletion osu.Game/Localisation/ModSelectOverlayStrings.cs
Original file line number Diff line number Diff line change
Expand Up @@ -14,10 +14,16 @@ public static class ModSelectOverlayStrings
/// </summary>
public static LocalisableString ModSelectTitle => new TranslatableString(getKey(@"mod_select_title"), @"Mod Select");

/// <summary>
/// "{0} mods"
/// </summary>
public static LocalisableString Mods(int count) => new TranslatableString(getKey(@"mods"), @"{0} mods", count);

/// <summary>
/// "Mods provide different ways to enjoy gameplay. Some have an effect on the score you can achieve during ranked play. Others are just for fun."
/// </summary>
public static LocalisableString ModSelectDescription => new TranslatableString(getKey(@"mod_select_description"), @"Mods provide different ways to enjoy gameplay. Some have an effect on the score you can achieve during ranked play. Others are just for fun.");
public static LocalisableString ModSelectDescription => new TranslatableString(getKey(@"mod_select_description"),
@"Mods provide different ways to enjoy gameplay. Some have an effect on the score you can achieve during ranked play. Others are just for fun.");

/// <summary>
/// "Mod Customisation"
Expand Down
2 changes: 1 addition & 1 deletion osu.Game/Screens/Select/FooterV2/FooterButtonModsV2.cs
Original file line number Diff line number Diff line change
Expand Up @@ -273,7 +273,7 @@ private partial class ModCountText : OsuSpriteText, IHasCustomTooltip<IReadOnlyL
protected override void LoadComplete()
{
base.LoadComplete();
Mods.BindValueChanged(v => Text = FooterButtonModsV2Strings.Mods(v.NewValue.Count).ToUpper(), true);
Mods.BindValueChanged(v => Text = ModSelectOverlayStrings.Mods(v.NewValue.Count).ToUpper(), true);
}

public ITooltip<IReadOnlyList<Mod>> GetCustomTooltip() => new ModTooltip(colourProvider);
Expand Down

0 comments on commit ac7598c

Please sign in to comment.