Don't convert global colormaps

This commit is contained in:
MascaraSnake 2022-01-09 10:38:05 +01:00
parent c1f03e7720
commit 5f6014223d

View file

@ -2035,15 +2035,25 @@ static void P_WriteTextmap(void)
{ {
INT32 s; INT32 s;
if (wlines[i].special != 606) switch (wlines[i].special)
continue;
TAG_ITER_SECTORS(wlines[i].args[0], s)
{ {
if (wsectors[s].colormap_protected) case 606:
continue; if (wlines[i].args[0] == MTAG_GLOBAL)
{
CONS_Printf("Linedef %d applies a global colormap which cannot be converted automatically. Please convert it manually.\n", i);
break;
}
wsectors[s].extra_colormap = wsides[wlines[i].sidenum[0]].colormap_data; TAG_ITER_SECTORS(wlines[i].args[0], s)
{
if (wsectors[s].colormap_protected)
continue;
wsectors[s].extra_colormap = wsides[wlines[i].sidenum[0]].colormap_data;
}
break;
default:
break;
} }
} }