diff --git a/src/Ryujinx.Common/TitleIDs.cs b/src/Ryujinx.Common/TitleIDs.cs index 890cf2793..24a6e364a 100644 --- a/src/Ryujinx.Common/TitleIDs.cs +++ b/src/Ryujinx.Common/TitleIDs.cs @@ -147,6 +147,7 @@ namespace Ryujinx.Common "0100c1f0051b6000", // Donkey Kong Country: Tropical Freeze "0100ed000d390000", // Dr. Kawashima's Brain Training "010067b017588000", // Endless Ocean Luminous + "01003da010e8a000", // Miitopia "01006b5012b32000", // Part Time UFO "0100704000B3A000", // Snipperclips "01006a800016e000", // Super Smash Bros. Ultimate diff --git a/src/Ryujinx/Systems/PlayReport/PlayReports.Formatters.cs b/src/Ryujinx/Systems/PlayReport/PlayReports.Formatters.cs index d8df7b627..90931e0cb 100644 --- a/src/Ryujinx/Systems/PlayReport/PlayReports.Formatters.cs +++ b/src/Ryujinx/Systems/PlayReport/PlayReports.Formatters.cs @@ -1088,5 +1088,33 @@ namespace Ryujinx.Ava.Systems.PlayReport return $"Living on {messagePackObjectDictionary["LandName"].AsString()} Island"; } + + private static FormattedValue MiitopiaRPC(SparseMultiValue values) + { + if (values.Matched.TryGetValue("gold", out Value gold) && values.Matched.TryGetValue("stage", out Value location)) + { + return $"{LocFinal(location.ToString())} with {gold} gold"; + } + + if (values.Matched.TryGetValue("secret", out Value secret)) // Yes "secret" is unused, but it only appears in the MII selector. + { + return $"In the MII selector"; + } + + return $"At the main menu"; + + static string LocFinal(string? location) => location switch + { + "0" => "Somewhere in Miitopia", + "1" => "Wandering around Greenhorne", + "2" => "Trodding through Neksdor", + "3" => "Exploring The Realm of the Fey", + "4" => "Burning their feet at Karkaton", + "5" => "Soaring in the skies of Miitopia", + "6" => "Fighting up The Sky Scraper", + "7" => "Traveling Miitopia", + _ => "Wandering" + }; + } } } diff --git a/src/Ryujinx/Systems/PlayReport/PlayReports.cs b/src/Ryujinx/Systems/PlayReport/PlayReports.cs index 8880ed5d4..16ff80933 100644 --- a/src/Ryujinx/Systems/PlayReport/PlayReports.cs +++ b/src/Ryujinx/Systems/PlayReport/PlayReports.cs @@ -132,6 +132,12 @@ namespace Ryujinx.Ava.Systems.PlayReport .WithDescription("based on your island name.") .AddValueFormatter("AppCmn", AnimalCrossingNewHorizons_AppCommon) ) + .AddSpec( + "01003da010e8a000", // Miitopia 01003da010e8a000 + spec => spec + .WithDescription("based on gold count, report info only in the mii selector, and gamestage (progression)") + .AddSparseMultiValueFormatter(["gold", "secret", "stage"], MiitopiaRPC) + ) ); private static string Playing(string game) => $"Playing {game}";