- moved the declarations for the lighting thinkers to p_light.cpp.
Aside from the init function they are not needed anywhere else and that could also be placed into this file.
This commit is contained in:
parent
c12a85ee85
commit
76c18820cb
3 changed files with 190 additions and 170 deletions
|
|
@ -1039,6 +1039,7 @@ static void P_SetupSectorDamage(sector_t *sector, int damage, int interval, int
|
|||
// Sets up everything derived from 'sector->special' for one sector
|
||||
// ('fromload' is necessary to allow conversion upon savegame load.)
|
||||
//
|
||||
void P_SpawnLights(sector_t *sector);
|
||||
|
||||
void P_InitSectorSpecial(sector_t *sector, int special)
|
||||
{
|
||||
|
|
@ -1072,31 +1073,10 @@ void P_InitSectorSpecial(sector_t *sector, int special)
|
|||
|
||||
// [RH] Normal DOOM special or BOOM specialized?
|
||||
bool keepspecial = false;
|
||||
P_SpawnLights(sector);
|
||||
switch (sector->special)
|
||||
{
|
||||
case Light_Phased:
|
||||
new DPhased (sector, 48, 63 - (sector->lightlevel & 63));
|
||||
break;
|
||||
|
||||
// [RH] Hexen-like phased lighting
|
||||
case LightSequenceStart:
|
||||
new DPhased (sector);
|
||||
break;
|
||||
|
||||
case dLight_Flicker:
|
||||
new DLightFlash (sector);
|
||||
break;
|
||||
|
||||
case dLight_StrobeFast:
|
||||
new DStrobe (sector, STROBEBRIGHT, FASTDARK, false);
|
||||
break;
|
||||
|
||||
case dLight_StrobeSlow:
|
||||
new DStrobe (sector, STROBEBRIGHT, SLOWDARK, false);
|
||||
break;
|
||||
|
||||
case dLight_Strobe_Hurt:
|
||||
new DStrobe (sector, STROBEBRIGHT, FASTDARK, false);
|
||||
P_SetupSectorDamage(sector, 20, 32, 5, NAME_Slime, 0);
|
||||
break;
|
||||
|
||||
|
|
@ -1108,10 +1088,6 @@ void P_InitSectorSpecial(sector_t *sector, int special)
|
|||
P_SetupSectorDamage(sector, 5, 32, 0, NAME_Slime, 0);
|
||||
break;
|
||||
|
||||
case dLight_Glow:
|
||||
new DGlow (sector);
|
||||
break;
|
||||
|
||||
case dSector_DoorCloseIn30:
|
||||
new DDoor(sector, DDoor::doorWaitClose, 2, 0, 0, 30 * TICRATE);
|
||||
break;
|
||||
|
|
@ -1120,14 +1096,6 @@ void P_InitSectorSpecial(sector_t *sector, int special)
|
|||
P_SetupSectorDamage(sector, 20, 32, 256, NAME_None, SECF_ENDGODMODE|SECF_ENDLEVEL);
|
||||
break;
|
||||
|
||||
case dLight_StrobeSlowSync:
|
||||
new DStrobe (sector, STROBEBRIGHT, SLOWDARK, true);
|
||||
break;
|
||||
|
||||
case dLight_StrobeFastSync:
|
||||
new DStrobe (sector, STROBEBRIGHT, FASTDARK, true);
|
||||
break;
|
||||
|
||||
case dSector_DoorRaiseIn5Mins:
|
||||
new DDoor (sector, DDoor::doorWaitRaise, 2, TICRATE*30/7, 0, 5*60*TICRATE);
|
||||
break;
|
||||
|
|
@ -1142,10 +1110,6 @@ void P_InitSectorSpecial(sector_t *sector, int special)
|
|||
P_SetupSectorDamage(sector, 20, 32, 5, NAME_Slime, 0);
|
||||
break;
|
||||
|
||||
case dLight_FireFlicker:
|
||||
new DFireFlicker (sector);
|
||||
break;
|
||||
|
||||
case dDamage_LavaWimpy:
|
||||
P_SetupSectorDamage(sector, 5, 32, 256, NAME_Fire, SECF_DMGTERRAINFX);
|
||||
break;
|
||||
|
|
@ -1156,7 +1120,6 @@ void P_InitSectorSpecial(sector_t *sector, int special)
|
|||
|
||||
case dScroll_EastLavaDamage:
|
||||
P_SetupSectorDamage(sector, 5, 32, 256, NAME_Fire, SECF_DMGTERRAINFX);
|
||||
new DStrobe(sector, STROBEBRIGHT, FASTDARK, false);
|
||||
P_CreateScroller(EScroll::sc_floor, -4., 0, -1, int(sector - sectors), 0);
|
||||
keepspecial = true;
|
||||
break;
|
||||
|
|
@ -1167,7 +1130,6 @@ void P_InitSectorSpecial(sector_t *sector, int special)
|
|||
|
||||
case sLight_Strobe_Hurt:
|
||||
P_SetupSectorDamage(sector, 5, 32, 0, NAME_Slime, 0);
|
||||
new DStrobe (sector, STROBEBRIGHT, FASTDARK, false);
|
||||
break;
|
||||
|
||||
case sDamage_Hellslime:
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue