mirror of
https://github.com/crskycode/GARbro.git
synced 2026-07-08 01:30:18 +08:00
feat: HuneX initial support
This commit is contained in:
@@ -124,6 +124,11 @@ namespace GameRes.Formats.BGI
|
||||
{
|
||||
if (!file.View.AsciiEqual (4, "KO ARC20"))
|
||||
return null;
|
||||
return Open (file);
|
||||
}
|
||||
|
||||
protected ArcFile Open (ArcView file)
|
||||
{
|
||||
int count = file.View.ReadInt32 (12);
|
||||
if (!IsSaneCount (count))
|
||||
return null;
|
||||
@@ -152,7 +157,7 @@ namespace GameRes.Formats.BGI
|
||||
entry.Type = res.Type;
|
||||
else if (file.View.AsciiEqual (entry.Offset, "BSE 1."))
|
||||
entry.Type = "image";
|
||||
else if (file.View.AsciiEqual (entry.Offset+4, "bw "))
|
||||
else if (file.View.AsciiEqual (entry.Offset+5, "w "))
|
||||
entry.Type = "audio";
|
||||
}
|
||||
return new ArcFile (file, this, dir);
|
||||
|
||||
@@ -39,13 +39,13 @@ namespace GameRes.Formats.BGI
|
||||
public BgiAudio ()
|
||||
{
|
||||
Signatures = new uint[] { 0x40, 0 };
|
||||
Extensions = new string[] { "bw", "", "_bw" };
|
||||
Extensions = new string[] { "bw", "", "_bw", "hw" };
|
||||
}
|
||||
|
||||
public override SoundInput TryOpen (IBinaryStream file)
|
||||
{
|
||||
var header = file.ReadHeader (8);
|
||||
if (!header.AsciiEqual (4, "bw "))
|
||||
if (!header.AsciiEqual (4, "bw ") && !header.AsciiEqual (4, "hw "))
|
||||
return null;
|
||||
uint offset = header.ToUInt32 (0);
|
||||
if (offset >= file.Length)
|
||||
|
||||
Reference in New Issue
Block a user