mirror of
https://github.com/crskycode/GARbro.git
synced 2024-11-30 17:05:37 +08:00
(ReadMetaData): check unpacked bitmap signature.
This commit is contained in:
parent
6f1e850140
commit
722d907504
@ -66,6 +66,8 @@ namespace GameRes.Formats.Tactics
|
|||||||
{
|
{
|
||||||
reader.Unpack();
|
reader.Unpack();
|
||||||
var bmp = reader.Data;
|
var bmp = reader.Data;
|
||||||
|
if (bmp[0] != 'B' || bmp[1] != 'M')
|
||||||
|
return null;
|
||||||
return new TgfMetaData
|
return new TgfMetaData
|
||||||
{
|
{
|
||||||
Width = LittleEndian.ToUInt32 (bmp, 0x12),
|
Width = LittleEndian.ToUInt32 (bmp, 0x12),
|
||||||
|
Loading…
Reference in New Issue
Block a user