fix bug in fsnitro FAT reading; fixes #63

This commit is contained in:
zeromus 2017-04-28 20:53:40 -05:00
parent bc2e1d99d3
commit 9357fd79e3
1 changed files with 1 additions and 2 deletions

View File

@ -146,10 +146,9 @@ bool FS_NITRO::loadFileTables()
fnt = new FNT_NITRO[numDirs];
// ========= FAT (File Allocation Table)
gameInfo.reader->Seek(gameInfo.fROM, FATOff, SEEK_SET);
for (u32 i = 0; i < numFiles; i++)
{
const u32 ofs = (i * 2);
gameInfo.reader->Seek(gameInfo.fROM, FATOff + ofs, SEEK_SET);
gameInfo.reader->Read(gameInfo.fROM, &fat[i].start, 4);
gameInfo.reader->Read(gameInfo.fROM, &fat[i].end, 4);
fat[i].size = fat[i].end - fat[i].start;