From 31f96f1306bbfb68eb721dd535f652a2af105113 Mon Sep 17 00:00:00 2001 From: CasualPokePlayer <50538166+CasualPokePlayer@users.noreply.github.com> Date: Tue, 25 Jan 2022 23:37:27 -0800 Subject: [PATCH] let's make this a little nicer --- src/BizHawk.Emulation.Cores/Waterbox/NymaCore.Settings.cs | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/BizHawk.Emulation.Cores/Waterbox/NymaCore.Settings.cs b/src/BizHawk.Emulation.Cores/Waterbox/NymaCore.Settings.cs index 24a625f555..35cc2e186e 100644 --- a/src/BizHawk.Emulation.Cores/Waterbox/NymaCore.Settings.cs +++ b/src/BizHawk.Emulation.Cores/Waterbox/NymaCore.Settings.cs @@ -275,6 +275,9 @@ namespace BizHawk.Emulation.Cores.Waterbox foreach (var portInfo in allPorts) { + if (s.AllOverrides.ContainsKey(portInfo.FullName) && s.AllOverrides[portInfo.FullName].Default != null) + portInfo.DefaultDeviceShortName = s.AllOverrides[portInfo.FullName].Default; + s.Ports.Add(new NymaSettingsInfo.Port { Name = portInfo.FullName, @@ -286,8 +289,6 @@ namespace BizHawk.Emulation.Cores.Waterbox SettingValue = dev.ShortName }).ToList() }); - if (s.AllOverrides.ContainsKey(portInfo.FullName) && s.AllOverrides[portInfo.FullName].Default != null) - portInfo.DefaultDeviceShortName = s.Ports.Last().DefaultSettingsValue = s.AllOverrides[portInfo.FullName].Default; } var originalSettings = GetSettingsData();