public NroAssetHeader(BinaryReader reader) { Magic = reader.ReadAscii(4); Version = reader.ReadUInt32(); for (int i = 0; i < 3; i++) { NroAssetSections[i] = new NroAssetSection(reader, (NroAssetType)i); } }
public IStorage OpenNroAssetSection(NroAssetType type, bool leaveOpen) { NroAssetSection header = AssetHeader.NroAssetSections[(int)type]; if (header.Size <= 0) { return(new NullStorage(0)); } return(AssetStorage.Slice(header.FileOffset, header.Size, leaveOpen)); }