Adapt linedef types 600-601 to UDMF

This commit is contained in:
MascaraSnake 2021-09-20 08:36:55 +02:00
parent 609fb91e4b
commit 1b339a9e00
3 changed files with 31 additions and 9 deletions

View file

@ -3371,6 +3371,23 @@ udmf
light light
{ {
600
{
title = "Copy Light Level to Tagged Sector's Planes";
prefix = "(600)";
arg0
{
title = "Target sector tag";
type = 13;
}
arg1
{
title = "Affected planes";
type = 11;
enum = "floorceiling";
}
}
602 602
{ {
title = "Start Adjustable Pulsating Light"; title = "Start Adjustable Pulsating Light";

View file

@ -4035,6 +4035,12 @@ static void P_ConvertBinaryMap(void)
lines[i].args[4] |= TMPF_NONEXCLUSIVE; lines[i].args[4] |= TMPF_NONEXCLUSIVE;
lines[i].special = 541; lines[i].special = 541;
break; break;
case 600: //Floor lighting
case 601: //Ceiling lighting
lines[i].args[0] = tag;
lines[i].args[1] = (lines[i].special == 601) ? TMP_CEILING : TMP_FLOOR;
lines[i].special = 600;
break;
case 606: //Colormap case 606: //Colormap
lines[i].args[0] = Tag_FGet(&lines[i].tags); lines[i].args[0] = Tag_FGet(&lines[i].tags);
break; break;

View file

@ -6859,16 +6859,15 @@ void P_SpawnSpecials(boolean fromnetsave)
// 546 is used for downwards current // 546 is used for downwards current
// 547 is used for push/pull // 547 is used for push/pull
case 600: // floor lighting independently (e.g. lava) case 600: // Copy light level to tagged sector's planes
sec = sides[*lines[i].sidenum].sector-sectors; sec = sides[*lines[i].sidenum].sector-sectors;
TAG_ITER_SECTORS(tag, s) TAG_ITER_SECTORS(lines[i].args[0], s)
sectors[s].floorlightsec = (INT32)sec; {
break; if (lines[i].args[1] != TMP_CEILING)
sectors[s].floorlightsec = (INT32)sec;
case 601: // ceiling lighting independently if (lines[i].args[1] != TMP_FLOOR)
sec = sides[*lines[i].sidenum].sector-sectors; sectors[s].ceilinglightsec = (INT32)sec;
TAG_ITER_SECTORS(tag, s) }
sectors[s].ceilinglightsec = (INT32)sec;
break; break;
case 602: // Adjustable pulsating light case 602: // Adjustable pulsating light