Remove NES _iskeyboard - This is implemented (although not well tested) already
This commit is contained in:
parent
26d74650d2
commit
b24d341b14
|
@ -69,7 +69,6 @@ namespace BizHawk.Emulation.Cores.Nintendo.NES
|
||||||
case "HVC-FAMILYBASIC":
|
case "HVC-FAMILYBASIC":
|
||||||
// we don't emulate the controller, so this won't work
|
// we don't emulate the controller, so this won't work
|
||||||
AssertPrg(32); AssertChr(8); AssertWram(2, 4);
|
AssertPrg(32); AssertChr(8); AssertWram(2, 4);
|
||||||
NES._iskeyboard = true;
|
|
||||||
break;
|
break;
|
||||||
|
|
||||||
default:
|
default:
|
||||||
|
|
|
@ -35,8 +35,6 @@ namespace BizHawk.Emulation.Cores.Nintendo.NES
|
||||||
//user configuration
|
//user configuration
|
||||||
int[] palette_compiled = new int[64 * 8];
|
int[] palette_compiled = new int[64 * 8];
|
||||||
|
|
||||||
//variable to change controller read/write behaviour when keyboard is attached
|
|
||||||
public bool _iskeyboard = false;
|
|
||||||
//variable set when VS system games are running
|
//variable set when VS system games are running
|
||||||
internal bool _isVS = false;
|
internal bool _isVS = false;
|
||||||
//some VS games have a ppu that switches 2000 and 2001, so keep trcak of that
|
//some VS games have a ppu that switches 2000 and 2001, so keep trcak of that
|
||||||
|
@ -577,12 +575,7 @@ namespace BizHawk.Emulation.Cores.Nintendo.NES
|
||||||
}
|
}
|
||||||
case 0x4017:
|
case 0x4017:
|
||||||
{
|
{
|
||||||
if (_iskeyboard)
|
if (_isVS)
|
||||||
{
|
|
||||||
// eventually this will be the keyboard function, but for now it is a place holder (no keys pressed)
|
|
||||||
return 0x1E;
|
|
||||||
}
|
|
||||||
else if (_isVS)
|
|
||||||
{
|
{
|
||||||
byte ret = 0;
|
byte ret = 0;
|
||||||
// for whatever reason, in VS left and right controller have swapped regs
|
// for whatever reason, in VS left and right controller have swapped regs
|
||||||
|
@ -674,11 +667,7 @@ namespace BizHawk.Emulation.Cores.Nintendo.NES
|
||||||
case 0x4014: Exec_OAMDma(val); break;
|
case 0x4014: Exec_OAMDma(val); break;
|
||||||
case 0x4015: apu.WriteReg(addr, val); break;
|
case 0x4015: apu.WriteReg(addr, val); break;
|
||||||
case 0x4016:
|
case 0x4016:
|
||||||
if (_iskeyboard)
|
if (_isVS)
|
||||||
{
|
|
||||||
// eventually keyboard emulation will go here
|
|
||||||
}
|
|
||||||
else if (_isVS)
|
|
||||||
{
|
{
|
||||||
write_joyport(val);
|
write_joyport(val);
|
||||||
VS_chr_reg = (byte)((val & 0x4)>>2);
|
VS_chr_reg = (byte)((val & 0x4)>>2);
|
||||||
|
|
|
@ -63,7 +63,6 @@ namespace BizHawk.Emulation.Cores.Nintendo.NES
|
||||||
ser.Sync("cpu_step", ref cpu_step);
|
ser.Sync("cpu_step", ref cpu_step);
|
||||||
ser.Sync("cpu_stepcounter", ref cpu_stepcounter);
|
ser.Sync("cpu_stepcounter", ref cpu_stepcounter);
|
||||||
ser.Sync("cpu_deadcounter", ref cpu_deadcounter);
|
ser.Sync("cpu_deadcounter", ref cpu_deadcounter);
|
||||||
ser.Sync("keyboard", ref _iskeyboard);
|
|
||||||
|
|
||||||
//oam related
|
//oam related
|
||||||
ser.Sync("Oam_Dma_Index", ref oam_dma_index);
|
ser.Sync("Oam_Dma_Index", ref oam_dma_index);
|
||||||
|
|
Loading…
Reference in New Issue