(GSP): adjusted entry size calculation.

This commit is contained in:
morkt 2017-02-02 11:01:39 +04:00
parent 5c9d56c841
commit 476b43cc4b

View File

@ -118,7 +118,7 @@ namespace GameRes.Formats.BlackRainbow
} }
var entry = FormatCatalog.Instance.Create<Entry> (name); var entry = FormatCatalog.Instance.Create<Entry> (name);
entry.Offset = offset + 0x24; entry.Offset = offset + 0x24;
entry.Size = i + 1 < index.Count ? (uint)(index[i+1] - offset) : (uint)(file.MaxOffset - offset); entry.Size = (uint)((i + 1 < index.Count ? index[i+1] : file.MaxOffset) - entry.Offset);
dir.Add (entry); dir.Add (entry);
} }
return new ArcFile (file, this, dir); return new ArcFile (file, this, dir);