mirror of
https://github.com/DrBeef/Raze.git
synced 2025-04-04 07:00:54 +00:00
- SW: precacheMap cleanup
This commit is contained in:
parent
b73ea76c18
commit
ec63dd4cb3
1 changed files with 15 additions and 15 deletions
|
@ -77,57 +77,57 @@ void precacheMap(void)
|
|||
WALLp wp;
|
||||
SPRITEp sp;
|
||||
|
||||
for (sectp = §or[0]; sectp < §or[numsectors]; sectp++)
|
||||
for(auto& sec : sectors())
|
||||
{
|
||||
j = sectp->ceilingpicnum;
|
||||
markTileForPrecache(j, sectp->ceilingpal);
|
||||
j = sec.ceilingpicnum;
|
||||
markTileForPrecache(j, sec.ceilingpal);
|
||||
|
||||
if (TEST(picanm[j].sf, PICANM_ANIMTYPE_MASK) >> PICANM_ANIMTYPE_SHIFT)
|
||||
{
|
||||
for (i = 1; i <= picanm[j].num; i++)
|
||||
{
|
||||
markTileForPrecache(j + i, sectp->ceilingpal);
|
||||
markTileForPrecache(j + i, sec.ceilingpal);
|
||||
}
|
||||
}
|
||||
|
||||
j = sectp->floorpicnum;
|
||||
j = sec.floorpicnum;
|
||||
|
||||
markTileForPrecache(j, sectp->floorpal);
|
||||
markTileForPrecache(j, sec.floorpal);
|
||||
|
||||
if (TEST(picanm[j].sf, PICANM_ANIMTYPE_MASK) >> PICANM_ANIMTYPE_SHIFT)
|
||||
{
|
||||
for (i = 1; i <= picanm[j].num; i++)
|
||||
{
|
||||
markTileForPrecache(j + i, sectp->floorpal);
|
||||
markTileForPrecache(j + i, sec.floorpal);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
for (wp = &wall[0]; wp < &wall[numwalls]; wp++)
|
||||
for (auto& wal : walls())
|
||||
{
|
||||
j = wp->picnum;
|
||||
j = wal.picnum;
|
||||
|
||||
markTileForPrecache(j, wp->pal);
|
||||
markTileForPrecache(j, wal.pal);
|
||||
|
||||
if (TEST(picanm[j].sf, PICANM_ANIMTYPE_MASK) >> PICANM_ANIMTYPE_SHIFT)
|
||||
{
|
||||
for (i = 1; i <= picanm[j].num; i++)
|
||||
{
|
||||
markTileForPrecache(j + i, wp->pal);
|
||||
markTileForPrecache(j + i, wal.pal);
|
||||
}
|
||||
}
|
||||
|
||||
if (wp->overpicnum > 0 && wp->overpicnum < MAXTILES)
|
||||
if (wal.overpicnum > 0 && wal.overpicnum < MAXTILES)
|
||||
{
|
||||
j = wp->overpicnum;
|
||||
markTileForPrecache(j, wp->pal);
|
||||
j = wal.overpicnum;
|
||||
markTileForPrecache(j, wal.pal);
|
||||
|
||||
if (TEST(picanm[j].sf, PICANM_ANIMTYPE_MASK) >> PICANM_ANIMTYPE_SHIFT)
|
||||
{
|
||||
for (i = 1; i <= picanm[j].num; i++)
|
||||
{
|
||||
markTileForPrecache(j + i, wp->pal);
|
||||
markTileForPrecache(j + i, wal.pal);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue