From b0123ea13328624d21b1bf19e625c6bb701403d9 Mon Sep 17 00:00:00 2001 From: alyosha-tas Date: Fri, 5 Jul 2019 17:16:11 -0400 Subject: [PATCH] Vectrex: fix control stick in some cases --- .../Consoles/GCE/Vectrex/HW_Registers.cs | 80 +++++++++---------- 1 file changed, 38 insertions(+), 42 deletions(-) diff --git a/BizHawk.Emulation.Cores/Consoles/GCE/Vectrex/HW_Registers.cs b/BizHawk.Emulation.Cores/Consoles/GCE/Vectrex/HW_Registers.cs index 26e4a88211..04a105aa27 100644 --- a/BizHawk.Emulation.Cores/Consoles/GCE/Vectrex/HW_Registers.cs +++ b/BizHawk.Emulation.Cores/Consoles/GCE/Vectrex/HW_Registers.cs @@ -209,33 +209,31 @@ namespace BizHawk.Emulation.Cores.Consoles.Vectrex } } } + + if (sel0) + { + if (sel1) + { + if (portA_ret >= joy2_UD) { compare = true; } + else { compare = false; } + } + else + { + if (portA_ret >= joy1_UD) { compare = true; } + else { compare = false; } + } + } else { - if (sel0) + if (sel1) { - if (sel1) - { - if (portA_ret >= joy2_UD) { compare = true; } - else { compare = false; } - } - else - { - if (portA_ret >= joy1_UD) { compare = true; } - else { compare = false; } - } + if (portA_ret >= joy2_LR) { compare = true; } + else { compare = false; } } else { - if (sel1) - { - if (portA_ret >= joy2_LR) { compare = true; } - else { compare = false; } - } - else - { - if (portA_ret >= joy1_LR) { compare = true; } - else { compare = false; } - } + if (portA_ret >= joy1_LR) { compare = true; } + else { compare = false; } } } @@ -288,33 +286,31 @@ namespace BizHawk.Emulation.Cores.Consoles.Vectrex } } } + + if (sel0) + { + if (sel1) + { + if (portA_ret >= joy2_UD) { compare = true; } + else { compare = false; } + } + else + { + if (portA_ret >= joy1_UD) { compare = true; } + else { compare = false; } + } + } else { - if (sel0) + if (sel1) { - if (sel1) - { - if (portA_ret >= joy2_UD) { compare = true; } - else { compare = false; } - } - else - { - if (portA_ret >= joy1_UD) { compare = true; } - else { compare = false; } - } + if (portA_ret >= joy2_LR) { compare = true; } + else { compare = false; } } else { - if (sel1) - { - if (portA_ret >= joy2_LR) { compare = true; } - else { compare = false; } - } - else - { - if (portA_ret >= joy1_LR) { compare = true; } - else { compare = false; } - } + if (portA_ret >= joy1_LR) { compare = true; } + else { compare = false; } } }