hook up the InputCallBackSystem to C64

This commit is contained in:
adelikat 2013-11-16 22:12:29 +00:00
parent 51f340fa76
commit def23fbd0f
3 changed files with 6 additions and 2 deletions

View File

@ -28,7 +28,7 @@ namespace BizHawk.Emulation.Cores.Computers.Commodore64
private void Init(Region initRegion) private void Init(Region initRegion)
{ {
board = new Motherboard(initRegion); board = new Motherboard(this, initRegion);
InitRoms(); InitRoms();
board.Init(); board.Init();
InitMedia(); InitMedia();

View File

@ -32,6 +32,7 @@
public void PollInput() public void PollInput()
{ {
_c64.CoreComm.InputCallback.Call();
// scan joysticks // scan joysticks
pollIndex = 0; pollIndex = 0;
for (int j = 0; j < 5; j++) for (int j = 0; j < 5; j++)

View File

@ -37,9 +37,12 @@ namespace BizHawk.Emulation.Cores.Computers.Commodore64
public bool irq; public bool irq;
public bool nmi; public bool nmi;
public Motherboard(Region initRegion) private C64 _c64;
public Motherboard(C64 c64, Region initRegion)
{ {
// note: roms need to be added on their own externally // note: roms need to be added on their own externally
_c64 = c64;
cartPort = new CartridgePort(); cartPort = new CartridgePort();
cassPort = new CassettePort(); cassPort = new CassettePort();