1
0
mirror of https://github.com/ppy/osu.git synced 2024-09-22 14:07:25 +08:00

Adjust mode part

This commit is contained in:
Andrei Zavatski 2020-01-30 13:56:19 +03:00
parent 3f62c40e70
commit 3002366e70
2 changed files with 32 additions and 3 deletions

View File

@ -41,8 +41,37 @@ namespace osu.Game.Online.API.Requests.Responses
[JsonProperty("count")]
public int Count;
public string Mode { get; private set; }
[JsonProperty("mode")]
public string Mode;
private string mode
{
set
{
switch (value)
{
default:
Mode = value;
return;
case "osu":
Mode = "osu!";
return;
case "mania":
Mode = "osu!mania";
return;
case "taiko":
Mode = "osu!taiko";
return;
case "fruits":
Mode = "osu!catch";
return;
}
}
}
[JsonProperty("beatmap")]
public RecentActivityBeatmap Beatmap;

View File

@ -185,14 +185,14 @@ namespace osu.Game.Overlays.Profile.Sections.Recent
addUserLink();
addText($" achieved rank #{activity.Rank} on ");
addBeatmapLink();
addText($" ({activity.Mode}!)");
addText($" ({activity.Mode})");
break;
case RecentActivityType.RankLost:
addUserLink();
addText(" has lost first place on ");
addBeatmapLink();
addText($" ({activity.Mode}!)");
addText($" ({activity.Mode})");
break;
case RecentActivityType.UserSupportAgain: