Esempio n. 1
0
        // Memory on the Gameboy is mapped. A memory read to a specific address can read the cart, ram, IO, OAM etc depending on the address
        public Memory(DmgSystem dmg)
        {
            this.dmg = dmg;

            GameRom      = dmg.rom;
            BootstrapRom = dmg.bootstrapRom;
            ppu          = dmg.ppu;
            interrupts   = dmg.interrupts;

            Ram    = new byte[0x2000];
            VRam   = new byte[0x2000];
            OamRam = new Byte[0x100];
            Io     = new Byte[0x100];
            HRam   = new Byte[0x80];
        }
Esempio n. 2
0
 public Interrupts(DmgSystem dmg)
 {
     this.dmg = dmg;
 }
Esempio n. 3
0
 public Ppu(DmgSystem dmg)
 {
     this.dmg = dmg;
 }
Esempio n. 4
0
 public DmgTimer(DmgSystem dmg)
 {
     this.dmg = dmg;
 }
Esempio n. 5
0
 public Joypad(Interrupts interrupts, DmgSystem dmg)
 {
     this.dmg        = dmg;
     this.interrupts = interrupts;
 }