From 6d77f5a3c0884be7f62c52d34c934d5b7a15225f Mon Sep 17 00:00:00 2001 From: adelikat Date: Thu, 13 Jul 2017 12:02:08 -0500 Subject: [PATCH] virtual pads for picoDrive --- .../tools/VirtualPads/schema/GenSchema.cs | 20 ++++++++++++++++++- 1 file changed, 19 insertions(+), 1 deletion(-) diff --git a/BizHawk.Client.EmuHawk/tools/VirtualPads/schema/GenSchema.cs b/BizHawk.Client.EmuHawk/tools/VirtualPads/schema/GenSchema.cs index ff964a6048..32f4c0717e 100644 --- a/BizHawk.Client.EmuHawk/tools/VirtualPads/schema/GenSchema.cs +++ b/BizHawk.Client.EmuHawk/tools/VirtualPads/schema/GenSchema.cs @@ -3,6 +3,7 @@ using System.Drawing; using BizHawk.Emulation.Common; using BizHawk.Emulation.Cores.Consoles.Sega.gpgx; +using BizHawk.Emulation.Cores.Consoles.Sega.PicoDrive; namespace BizHawk.Client.EmuHawk { @@ -11,7 +12,24 @@ namespace BizHawk.Client.EmuHawk { public IEnumerable GetPadSchemas(IEmulator core) { - var devs = ((GPGX)core).GetDevices(); + if (core is GPGX) + { + return GpgxPadSchemas((GPGX)core); + } + + return PicoPadSchemas((PicoDrive)core); + } + + private IEnumerable PicoPadSchemas(PicoDrive core) + { + yield return SixButtonController(1); + yield return SixButtonController(2); + yield return ConsoleButtons(); + } + + private IEnumerable GpgxPadSchemas(GPGX core) + { + var devs = (core).GetDevices(); int player = 1; foreach (var dev in devs) {