From 116f41a99155f8d0966b1afeb3df7d2df449b3b0 Mon Sep 17 00:00:00 2001 From: freezy Date: Tue, 17 Nov 2026 21:19:33 +0100 Subject: [PATCH] pinmame: show compatible ROMs on two lines and title the choice "ROM" Each choice shows the game's name, with the ROM's ID smaller and dimmer below. --- .../Runtime/PinMamePluginFactory.cs | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/VisualPinball.Engine.PinMAME.Unity/Runtime/PinMamePluginFactory.cs b/VisualPinball.Engine.PinMAME.Unity/Runtime/PinMamePluginFactory.cs index 03a20e6..916cf57 100644 --- a/VisualPinball.Engine.PinMAME.Unity/Runtime/PinMamePluginFactory.cs +++ b/VisualPinball.Engine.PinMAME.Unity/Runtime/PinMamePluginFactory.cs @@ -43,7 +43,7 @@ internal sealed partial class PinMamePluginFactory : IPlayerPluginFactory, IPlug Presentation = PluginFieldPresentation.Slider, Unit = "%", Scope = ConfigurationScope.GlobalAndGame, VisibleWhen = "AltSound", Description = "How much of the ROM's own sound still plays, for packs that don't replace all of it. Off, like Visual PinMAME." }), new PluginSettingsGroup("ROM", "", - new PluginField(CompatibleRomField, "Compatible ROM", SettingKind.Choice) { Scope = ConfigurationScope.GameOnly, Provider = CompatibleRomsProvider, Default = "", + new PluginField(CompatibleRomField, "ROM", SettingKind.Choice) { Scope = ConfigurationScope.GameOnly, Provider = CompatibleRomsProvider, Default = "", Description = "The ROM to play when the one this table was made for isn't in your ROM folder. The table lists the ROMs that run the same machine." }), new PluginSettingsGroup("ROM memory", "Tables using the same ROM share its saved memory.", new PluginField("ResetRomMemory", "Back up and reset ROM memory", SettingKind.Action) { Scope = ConfigurationScope.GameOnly, Provider = ResetRomMemory, @@ -92,8 +92,9 @@ private static PluginChoiceCatalog CompatibleRomCatalog(string package, Cancella private static string ChoiceLabel(PinMameCompatibleRom rom) { - var label = string.IsNullOrWhiteSpace(rom.Description) ? rom.Id : $"{rom.Description} · {rom.Id}"; - return rom.Compatibility == PinMameRomCompatibility.Unverified ? label + " (unverified)" : label; + // two lines: the game's name, then the ROM's ID, smaller and dimmer + var detail = rom.Compatibility == PinMameRomCompatibility.Unverified ? rom.Id + " · unverified" : rom.Id; + return string.IsNullOrWhiteSpace(rom.Description) ? detail : $"{rom.Description}\n{detail}"; } private static string Explain(PinMameCompatibleRom rom) => rom.Compatibility switch {