(XP3): parse "sen:" section.

This commit is contained in:
morkt
2018-04-03 04:50:09 +04:00
parent 3a9e5de5c8
commit 6182cadc88

View File

@@ -250,17 +250,17 @@ namespace GameRes.Formats.KiriKiri
dir.Add (entry);
}
}
else if (0x3A7A7579 == entry_signature) // "yuz:"
else if (0x3A7A7579 == entry_signature || 0x3A6E6573 == entry_signature) // "yuz:" || "sen:"
{
if (entry_size >= 0x10 && crypt_algorithm.Value is RiddleCxCrypt)
if (entry_size >= 0x10 && crypt_algorithm.Value is SenrenCxCrypt)
{
long offset = header.ReadInt64();
long offset = header.ReadInt64() + base_offset;
header.ReadUInt32(); // unpacked size
uint size = header.ReadUInt32();
if (offset > 0 && offset + size <= file.MaxOffset)
{
var yuz = file.View.ReadBytes (offset, size);
var crypt = crypt_algorithm.Value as RiddleCxCrypt;
var crypt = crypt_algorithm.Value as SenrenCxCrypt;
crypt.ReadYuzNames (yuz, filename_map);
}
}