Beispiel #1
0
 private void Initialize(RenderWindow window)
 {
     ppu     = new Ppu(window);
     cpu     = new Cpu();
     control = new Controls();
     tracer  = new Tracer();
 }
Beispiel #2
0
        public NES(Cartridge gameCartridge, Joypad joypad)
        {
            var ppuBus = new PpuBus(gameCartridge.CharacterRom, gameCartridge.GameMirroring);

            _ppu = new Ppu(ppuBus, new NmiTrigger(() => _cpu.NMI()));

            var cpuBus = new CpuBus(gameCartridge.ProgramRom, _ppu, joypad, new DMA(PerformDma), () => _cpu.MasterClockCycles);

            _cpu = new Cpu(cpuBus);
        }