updated formats.

(PICT): fixed 16bpp images.
(GDT): added image format.
(DXR): tweaks to recognizing DXR inside exe files.
(NSA): recognize mp3 files named as nsa.
(TLZ): added ContainedFormats.
(WrapSingleFileAchive): class that represents single file as an archive.
(DesertCgOPener): Software House Parsley archive.
(Triangle.RleReader): utilize UnpackV2, replaced BinaryReader with IBinaryStream.
This commit is contained in:
morkt
2023-10-11 18:38:23 +04:00
parent e4e85fe879
commit 1b585ea30e
11 changed files with 872 additions and 40 deletions

View File

@@ -39,6 +39,11 @@ namespace GameRes.Formats.Otemoto
public override bool IsHierarchic { get { return false; } }
public override bool CanWrite { get { return false; } }
public TlzOpener ()
{
ContainedFormats = new[] { "BMP", "SCR" };
}
public override ArcFile TryOpen (ArcView file)
{
int count = file.View.ReadInt32 (0xC);
@@ -61,7 +66,7 @@ namespace GameRes.Formats.Otemoto
if (0 == name_length || name_length > 0x100)
return null;
entry.Name = file.View.ReadString (index_offset+0x10, name_length);
entry.Type = FormatCatalog.Instance.GetTypeFromName (entry.Name);
entry.Type = FormatCatalog.Instance.GetTypeFromName (entry.Name, ContainedFormats);
entry.IsPacked = entry.UnpackedSize != entry.Size;
dir.Add (entry);
index_offset += 0x10 + name_length;
@@ -78,4 +83,9 @@ namespace GameRes.Formats.Otemoto
return new LzssStream (input);
}
}
[Export(typeof(ResourceAlias))]
[ExportMetadata("Extension", "SNR")]
[ExportMetadata("Target", "SCR")]
internal class SnrFormat : ResourceAlias { }
}

View File

@@ -45,7 +45,7 @@ namespace GameRes.Formats.Otemoto
[Export(typeof(ImageFormat))]
public class MagFormat : ImageFormat
{
public override string Tag { get { return "MAG"; } }
public override string Tag { get { return "MAG/MAKI02"; } }
public override string Description { get { return "Otemoto image format"; } }
public override uint Signature { get { return 0x494B414D; } } // 'MAKI02'