1
0
mirror of https://github.com/ppy/osu.git synced 2025-01-14 02:22:56 +08:00

Make beatmap title use unicode

This commit is contained in:
PercyDan54 2021-04-03 12:43:17 +08:00
parent 0c35128ead
commit bd7da9eb39
No known key found for this signature in database
GPG Key ID: 6AEA7C525131BAF3
2 changed files with 5 additions and 2 deletions

View File

@ -19,8 +19,10 @@ namespace osu.Game.Beatmaps
public int ID { get; set; }
public string Title { get; set; }
[JsonProperty("title_unicode")]
public string TitleUnicode { get; set; }
public string Artist { get; set; }
[JsonProperty("artist_unicode")]
public string ArtistUnicode { get; set; }
[JsonIgnore]

View File

@ -8,6 +8,7 @@ using osu.Framework.Graphics;
using osu.Framework.Graphics.Colour;
using osu.Framework.Graphics.Containers;
using osu.Framework.Graphics.Shapes;
using osu.Framework.Localisation;
using osu.Game.Beatmaps.Drawables;
using osu.Game.Graphics;
using osu.Game.Graphics.Sprites;
@ -228,8 +229,8 @@ namespace osu.Game.Overlays.BeatmapSet
loading.Hide();
title.Text = setInfo.NewValue.Metadata.Title ?? string.Empty;
artist.Text = setInfo.NewValue.Metadata.Artist ?? string.Empty;
title.Text = new RomanisableString(setInfo.NewValue.Metadata.TitleUnicode, setInfo.NewValue.Metadata.Title);
artist.Text = new RomanisableString(setInfo.NewValue.Metadata.ArtistUnicode, setInfo.NewValue.Metadata.Artist);
explicitContentPill.Alpha = setInfo.NewValue.OnlineInfo.HasExplicitContent ? 1 : 0;