diff options
Diffstat (limited to '')
-rw-r--r-- | NW4RTools/BrresReader.cs | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/NW4RTools/BrresReader.cs b/NW4RTools/BrresReader.cs index aa54437..8b9fcb1 100644 --- a/NW4RTools/BrresReader.cs +++ b/NW4RTools/BrresReader.cs @@ -10,10 +10,18 @@ namespace NW4RTools { return LoadFile(data, true); } + public static ResFile LoadFile(byte[] data, out SortedDictionary<int, string> offsetMap) { + return LoadFile(data, true, out offsetMap); + } + public static ResFile LoadFile(byte[] data, bool debug) { return new BrresReader(debug).Load(new InputStream(data, ByteEndian.BigEndian)); } + public static ResFile LoadFile(byte[] data, bool debug, out SortedDictionary<int, string> offsetMap) { + return new BrresReader(debug).Load(new InputStream(data, ByteEndian.BigEndian), out offsetMap); + } + private class RawStreamResDict : ResDict<InputStream> { @@ -35,6 +43,11 @@ namespace NW4RTools { } public ResFile Load(InputStream ins) { + SortedDictionary<int, string> trashThis; + return Load(ins, out trashThis); + } + + public ResFile Load(InputStream ins, out SortedDictionary<int, string> offsetMap) { File = new ResFile(); // Read BRRES header @@ -63,6 +76,7 @@ namespace NW4RTools { } } + offsetMap = OffsetMap; return File; } |