IBinaryStream migration.

This commit is contained in:
morkt
2016-10-16 09:22:53 +04:00
parent d0c1d5da01
commit bb18303eb4
251 changed files with 3277 additions and 3630 deletions

View File

@@ -132,7 +132,7 @@ namespace GameRes.Formats.MoonhirGames
var data = arc.File.View.ReadBytes (entry.Offset, entry.Size);
Decrypt (data, 0, data.Length, farc.Key);
int length = LittleEndian.ToInt32 (data, data.Length-8);
input = new MemoryStream (data, 0, length);
input = new BinMemoryStream (data, 0, length, entry.Name);
header = data;
}
if (!Binary.AsciiEqual (header, "FBX\x01"))
@@ -143,7 +143,7 @@ namespace GameRes.Formats.MoonhirGames
int unpacked_size = LittleEndian.ToInt32 (header, 0xC);
input.Position = header[7];
var unpacked = UnpackFbx (input, packed_size, unpacked_size);
return new MemoryStream (unpacked);
return new BinMemoryStream (unpacked, entry.Name);
}
}