Tiny fix, condensed things a bit

This commit is contained in:
neauoire 2021-03-28 12:14:37 -07:00
parent 09f4352161
commit e02a0e440f
1 changed files with 4 additions and 4 deletions

View File

@ -151,10 +151,10 @@ loadtheme(Uint8 *addr)
int i;
for(i = 0; i < 4; ++i) {
Uint8
r = (*(addr + i / 2) >> (!(i % 2) * 4)) & 0x0f,
g = (*(addr + 2 + i / 2) >> (!(i % 2) * 4)) & 0x0f,
b = (*(addr + 4 + i / 2) >> (!(i % 2) * 4)) & 0x0f;
theme[i] = ((r << 4) << 16) + ((g << 4) << 8) + (b << 4);
r = (*(addr + i / 2) >> (!(i % 2) << 2)) & 0x0f,
g = (*(addr + 2 + i / 2) >> (!(i % 2) << 2)) & 0x0f,
b = (*(addr + 4 + i / 2) >> (!(i % 2) << 2)) & 0x0f;
theme[i] = (r << 20) + (g << 12) + (b << 4);
}
screen.reqdraw = 1;
}