From 34ca844f397401dd01e071d63805030b8012ae31 Mon Sep 17 00:00:00 2001 From: morkt Date: Sat, 17 Nov 2018 00:45:14 +0400 Subject: [PATCH] (BND): added alias for scripts. --- Legacy/Tetratech/ArcBND.cs | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/Legacy/Tetratech/ArcBND.cs b/Legacy/Tetratech/ArcBND.cs index 9f986494..a01ddbef 100644 --- a/Legacy/Tetratech/ArcBND.cs +++ b/Legacy/Tetratech/ArcBND.cs @@ -28,6 +28,7 @@ using System.ComponentModel.Composition; using System.IO; // [010309][Tetratech] Kyouiku Jisshuu 2 ~Joshikousei Maniacs~ +// [031128][Kogado Studio] 指極星 namespace GameRes.Formats.Tetratech { @@ -40,6 +41,11 @@ namespace GameRes.Formats.Tetratech public override bool IsHierarchic { get { return false; } } public override bool CanWrite { get { return false; } } + public BndOpener () + { + ContainedFormats = new[] { "BMP", "WAV", "SCR" }; + } + public override ArcFile TryOpen (ArcView file) { if (!file.Name.HasExtension (".BND")) @@ -56,7 +62,7 @@ namespace GameRes.Formats.Tetratech for (int i = 0; i < count; ++i) { var name = idx.ReadCString (0x10); - var entry = FormatCatalog.Instance.Create (name); + var entry = Create (name); entry.Size = idx.ReadUInt32(); entry.Offset = idx.ReadUInt32(); if (!entry.CheckPlacement (file.MaxOffset)) @@ -67,4 +73,9 @@ namespace GameRes.Formats.Tetratech } } } + + [Export(typeof(ResourceAlias))] + [ExportMetadata("Extension", "SCB")] + [ExportMetadata("Target", "SCR")] + public class ScbFormat : ResourceAlias { } }