Formatting

This commit is contained in:
mazmazz 2018-09-12 08:06:44 -04:00
parent 7767adbf32
commit cb2ac9b4d3
1 changed files with 12 additions and 15 deletions

View File

@ -3287,26 +3287,23 @@ static void P_ProcessLineSpecial(line_t *line, mobj_t *mo, sector_t *callsec)
else else
Z_Free(exc); Z_Free(exc);
} }
else else if (line->flags & ML_DONTPEGBOTTOM) // alternate alpha (by texture offsets)
{ {
if (line->flags & ML_DONTPEGBOTTOM) // alternate alpha (by texture offsets) extracolormap_t *exc = R_CopyColormap(line->frontsector->extra_colormap, false);
{ exc->rgba = R_GetRgbaRGB(exc->rgba) + R_PutRgbaA(max(min(sides[line->sidenum[0]].textureoffset >> FRACBITS, 25), 0));
extracolormap_t *exc = R_CopyColormap(line->frontsector->extra_colormap, false); exc->fadergba = R_GetRgbaRGB(exc->fadergba) + R_PutRgbaA(max(min(sides[line->sidenum[0]].rowoffset >> FRACBITS, 25), 0));
exc->rgba = R_GetRgbaRGB(exc->rgba) + R_PutRgbaA(max(min(sides[line->sidenum[0]].textureoffset >> FRACBITS, 25), 0));
exc->fadergba = R_GetRgbaRGB(exc->fadergba) + R_PutRgbaA(max(min(sides[line->sidenum[0]].rowoffset >> FRACBITS, 25), 0));
if (!(sectors[secnum].extra_colormap = R_GetColormapFromList(exc))) if (!(sectors[secnum].extra_colormap = R_GetColormapFromList(exc)))
{ {
exc->colormap = R_CreateLightTable(exc); exc->colormap = R_CreateLightTable(exc);
R_AddColormapToList(exc); R_AddColormapToList(exc);
sectors[secnum].extra_colormap = exc; sectors[secnum].extra_colormap = exc;
}
else
Z_Free(exc);
} }
else else
sectors[secnum].extra_colormap = line->frontsector->extra_colormap; Z_Free(exc);
} }
else
sectors[secnum].extra_colormap = line->frontsector->extra_colormap;
} }
break; break;