mirror of
https://github.com/ZDoom/qzdoom.git
synced 2025-01-31 04:50:48 +00:00
Added compatibility parameter to set sector special
This commit is contained in:
parent
1fa37aaeb7
commit
94f7bef2ff
1 changed files with 20 additions and 0 deletions
|
@ -80,6 +80,7 @@ enum
|
||||||
CP_CLEARSPECIAL,
|
CP_CLEARSPECIAL,
|
||||||
CP_SETACTIVATION,
|
CP_SETACTIVATION,
|
||||||
CP_SECTORFLOOROFFSET,
|
CP_SECTORFLOOROFFSET,
|
||||||
|
CP_SETSECTORSPECIAL,
|
||||||
CP_SETWALLYSCALE,
|
CP_SETWALLYSCALE,
|
||||||
CP_SETTHINGZ,
|
CP_SETTHINGZ,
|
||||||
CP_SETTAG,
|
CP_SETTAG,
|
||||||
|
@ -294,6 +295,15 @@ void ParseCompatibility()
|
||||||
sc.MustGetFloat();
|
sc.MustGetFloat();
|
||||||
CompatParams.Push(int(sc.Float*65536.));
|
CompatParams.Push(int(sc.Float*65536.));
|
||||||
}
|
}
|
||||||
|
else if (sc.Compare("setsectorspecial"))
|
||||||
|
{
|
||||||
|
if (flags.ExtCommandIndex == ~0u) flags.ExtCommandIndex = CompatParams.Size();
|
||||||
|
CompatParams.Push(CP_SETSECTORSPECIAL);
|
||||||
|
sc.MustGetNumber();
|
||||||
|
CompatParams.Push(sc.Number);
|
||||||
|
sc.MustGetNumber();
|
||||||
|
CompatParams.Push(sc.Number);
|
||||||
|
}
|
||||||
else if (sc.Compare("setwallyscale"))
|
else if (sc.Compare("setwallyscale"))
|
||||||
{
|
{
|
||||||
if (flags.ExtCommandIndex == ~0u) flags.ExtCommandIndex = CompatParams.Size();
|
if (flags.ExtCommandIndex == ~0u) flags.ExtCommandIndex = CompatParams.Size();
|
||||||
|
@ -529,6 +539,16 @@ void SetCompatibilityParams()
|
||||||
i += 3;
|
i += 3;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
case CP_SETSECTORSPECIAL:
|
||||||
|
{
|
||||||
|
const int index = CompatParams[i + 1];
|
||||||
|
if (index < numsectors)
|
||||||
|
{
|
||||||
|
sectors[index].special = CompatParams[i + 2];
|
||||||
|
}
|
||||||
|
i += 3;
|
||||||
|
break;
|
||||||
|
}
|
||||||
case CP_SETWALLYSCALE:
|
case CP_SETWALLYSCALE:
|
||||||
{
|
{
|
||||||
if (CompatParams[i+1] < numlines)
|
if (CompatParams[i+1] < numlines)
|
||||||
|
|
Loading…
Reference in a new issue