- moved all 'sectorptr - &level.sectors[0]' constructs into a subfunction.

This commit is contained in:
Christoph Oelckers 2017-01-07 20:02:25 +01:00
commit 91981e25a8
13 changed files with 23 additions and 30 deletions

View file

@ -3179,11 +3179,11 @@ static void P_GroupLines (bool buildmap)
auto li = &lines[i];
if (li->frontsector != NULL)
{
li->frontsector->Lines[linesDoneInEachSector[li->frontsector - &level.sectors[0]]++] = li;
li->frontsector->Lines[linesDoneInEachSector[li->frontsector->Index()]++] = li;
}
if (li->backsector != NULL && li->backsector != li->frontsector)
{
li->backsector->Lines[linesDoneInEachSector[li->backsector - &level.sectors[0]]++] = li;
li->backsector->Lines[linesDoneInEachSector[li->backsector->Index()]++] = li;
}
}