- scriptified some trivial stuff from g_shared.

This commit is contained in:
Christoph Oelckers 2016-11-29 19:50:34 +01:00
commit a13e23dbe6
33 changed files with 276 additions and 502 deletions

View file

@ -700,6 +700,16 @@ void sector_t::SetColor(int r, int g, int b, int desat)
P_RecalculateAttachedLights(this);
}
DEFINE_ACTION_FUNCTION(_Sector, SetColor)
{
PARAM_SELF_STRUCT_PROLOGUE(sector_t);
PARAM_COLOR(color);
PARAM_INT(desat);
self->ColorMap = GetSpecialLights(color, self->ColorMap->Fade, desat);
P_RecalculateAttachedLights(self);
return 0;
}
void sector_t::SetFade(int r, int g, int b)
{
PalEntry fade = PalEntry (r,g,b);
@ -707,6 +717,16 @@ void sector_t::SetFade(int r, int g, int b)
P_RecalculateAttachedLights(this);
}
DEFINE_ACTION_FUNCTION(_Sector, SetFade)
{
PARAM_SELF_STRUCT_PROLOGUE(sector_t);
PARAM_COLOR(fade);
self->ColorMap = GetSpecialLights(self->ColorMap->Color, fade, self->ColorMap->Desaturate);
P_RecalculateAttachedLights(self);
return 0;
}
//===========================================================================
//
// sector_t :: ClosestPoint