Fix palette issues with cinema code

This commit is contained in:
nukeykt 2019-11-03 13:00:08 +09:00 committed by Christoph Oelckers
parent f04de71065
commit 6378082339
2 changed files with 7 additions and 0 deletions

View file

@ -1781,6 +1781,10 @@ int LoadCinemaPalette(int nPal)
} }
kread(hFile, cinemapal, sizeof(cinemapal)); kread(hFile, cinemapal, sizeof(cinemapal));
for (auto &c : cinemapal)
c <<= 2;
kclose(hFile); kclose(hFile);
return nPal; return nPal;

View file

@ -70,6 +70,9 @@ int ReadFrame(FILE *fp)
fread(palette, sizeof(palette[0]), sizeof(palette) / sizeof(palette[0]), fp); fread(palette, sizeof(palette[0]), sizeof(palette) / sizeof(palette[0]), fp);
fread(&var_1C, sizeof(var_1C), 1, fp); fread(&var_1C, sizeof(var_1C), 1, fp);
for (auto &c : palette)
c <<= 2;
paletteSetColorTable(ANIMPAL, palette); paletteSetColorTable(ANIMPAL, palette);
videoSetPalette(0, ANIMPAL, 2+8); videoSetPalette(0, ANIMPAL, 2+8);