コード例 #1
0
        public void WriteToRom(RomIO rom)
        {
            if (rom is null)
            {
                throw new ArgumentNullException(nameof(rom));
            }

            rom.WriteInt24(Address, Value);
        }
コード例 #2
0
        public void WriteToRom(RomIO rom)
        {
            if (rom is null)
            {
                throw new ArgumentNullException(nameof(rom));
            }

            rom.WriteBytes(_bytes, Address, CrossBanks);
        }
コード例 #3
0
        public Int24Reference(RomIO rom, int address)
        {
            if (rom is null)
            {
                throw new ArgumentNullException(nameof(rom));
            }

            Address = address;
            Value   = rom.ReadInt24(address);
        }
コード例 #4
0
        public ArrayReference(
            RomIO rom,
            int address,
            int count,
            bool crossBanks = true)
        {
            if (rom is null)
            {
                throw new ArgumentNullException(nameof(rom));
            }

            Address    = address;
            CrossBanks = crossBanks;

            _bytes = rom.ReadBytes(address, count, crossBanks);
            Bytes  = new Collection <byte>(_bytes);
        }
コード例 #5
0
 public AllStarsRomFile(string path)
 {
     Path        = path ?? throw new ArgumentNullException(nameof(path));
     Rom         = new RomIO(File.ReadAllBytes(path));
     Smb1RomData = new Smb1.RomData(Rom);
 }