mirror of
https://github.com/crskycode/GARbro.git
synced 2026-07-08 01:30:18 +08:00
(AssetReader): modified format behavior.
This commit is contained in:
@@ -91,20 +91,22 @@ namespace GameRes.Formats.Unity
|
|||||||
ReadInt32 = () => Binary.BigEndian (m_input.ReadInt32());
|
ReadInt32 = () => Binary.BigEndian (m_input.ReadInt32());
|
||||||
ReadInt64 = () => Binary.BigEndian (m_input.ReadInt64());
|
ReadInt64 = () => Binary.BigEndian (m_input.ReadInt64());
|
||||||
}
|
}
|
||||||
if (m_format >= 14)
|
if (m_format >= 14 || m_format == 9)
|
||||||
{
|
{
|
||||||
Align = () => {
|
Align = () => {
|
||||||
long pos = m_input.Position;
|
long pos = m_input.Position;
|
||||||
if (0 != (pos & 3))
|
if (0 != (pos & 3))
|
||||||
m_input.Position = (pos + 3) & ~3L;
|
m_input.Position = (pos + 3) & ~3L;
|
||||||
};
|
};
|
||||||
ReadId = ReadInt64;
|
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
Align = () => {};
|
Align = () => {};
|
||||||
ReadId = () => ReadInt32();
|
|
||||||
}
|
}
|
||||||
|
if (m_format >= 14)
|
||||||
|
ReadId = ReadInt64;
|
||||||
|
else
|
||||||
|
ReadId = () => ReadInt32();
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
|
|||||||
Reference in New Issue
Block a user