Merge branch 'rainfixesmkII' into 'master'
Accidentially broke rain in the rainfixes branch (oh, the irony!) See merge request STJr/SRB2Internal!249
This commit is contained in:
commit
c1bea02f03
|
@ -3190,8 +3190,8 @@ state_t states[NUMSTATES] =
|
||||||
{SPR_SSWB, 1, 1, {NULL}, 0, 0, S_BHORIZ1}, // S_BHORIZ8
|
{SPR_SSWB, 1, 1, {NULL}, 0, 0, S_BHORIZ1}, // S_BHORIZ8
|
||||||
|
|
||||||
// Rain
|
// Rain
|
||||||
{SPR_RAIN, FF_TRANS50, -1, {NULL}, 0, 0, S_NULL}, // S_RAIN1
|
{SPR_RAIN, FF_FULLBRIGHT|FF_TRANS50, -1, {NULL}, 0, 0, S_NULL}, // S_RAIN1
|
||||||
{SPR_RAIN, FF_TRANS50, 1, {NULL}, 0, 0, S_RAIN1}, // S_RAINRETURN
|
{SPR_RAIN, FF_FULLBRIGHT|FF_TRANS50, 1, {NULL}, 0, 0, S_RAIN1}, // S_RAINRETURN
|
||||||
|
|
||||||
// Snowflake
|
// Snowflake
|
||||||
{SPR_SNO1, 0, -1, {NULL}, 0, 0, S_NULL}, // S_SNOW1
|
{SPR_SNO1, 0, -1, {NULL}, 0, 0, S_NULL}, // S_SNOW1
|
||||||
|
@ -16118,7 +16118,7 @@ mobjinfo_t mobjinfo[NUMMOBJTYPES] =
|
||||||
S_NULL, // deathstate
|
S_NULL, // deathstate
|
||||||
S_NULL, // xdeathstate
|
S_NULL, // xdeathstate
|
||||||
sfx_None, // deathsound
|
sfx_None, // deathsound
|
||||||
-24*FRACUNIT, // speed
|
-72*FRACUNIT, // speed
|
||||||
1*FRACUNIT, // radius
|
1*FRACUNIT, // radius
|
||||||
8*FRACUNIT, // height
|
8*FRACUNIT, // height
|
||||||
0, // display offset
|
0, // display offset
|
||||||
|
|
|
@ -3130,7 +3130,7 @@ void EV_CrumbleChain(sector_t *sec, ffloor_t *rover)
|
||||||
// no longer exists (can't collide with again)
|
// no longer exists (can't collide with again)
|
||||||
rover->flags &= ~FF_EXISTS;
|
rover->flags &= ~FF_EXISTS;
|
||||||
rover->master->frontsector->moved = true;
|
rover->master->frontsector->moved = true;
|
||||||
sec->moved = true;
|
P_RecalcPrecipInSector(sec);
|
||||||
}
|
}
|
||||||
|
|
||||||
// Used for bobbing platforms on the water
|
// Used for bobbing platforms on the water
|
||||||
|
|
|
@ -9601,12 +9601,12 @@ consvar_t cv_flagtime = {"flagtime", "30", CV_NETVAR|CV_CHEAT, flagtime_cons_t,
|
||||||
|
|
||||||
void P_SpawnPrecipitation(void)
|
void P_SpawnPrecipitation(void)
|
||||||
{
|
{
|
||||||
INT32 i /*, j*/, mrand;
|
INT32 i, mrand;
|
||||||
fixed_t basex, basey, x, y, height;
|
fixed_t basex, basey, x, y, height;
|
||||||
subsector_t *precipsector = NULL;
|
subsector_t *precipsector = NULL;
|
||||||
precipmobj_t *rainmo = NULL;
|
precipmobj_t *rainmo = NULL;
|
||||||
|
|
||||||
if (dedicated || /*!cv_precipdensity*/!cv_drawdist_precip.value || curWeather == PRECIP_NONE)
|
if (dedicated || !(cv_drawdist_precip.value) || curWeather == PRECIP_NONE)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
// Use the blockmap to narrow down our placing patterns
|
// Use the blockmap to narrow down our placing patterns
|
||||||
|
@ -9615,8 +9615,6 @@ void P_SpawnPrecipitation(void)
|
||||||
basex = bmaporgx + (i % bmapwidth) * MAPBLOCKSIZE;
|
basex = bmaporgx + (i % bmapwidth) * MAPBLOCKSIZE;
|
||||||
basey = bmaporgy + (i / bmapwidth) * MAPBLOCKSIZE;
|
basey = bmaporgy + (i / bmapwidth) * MAPBLOCKSIZE;
|
||||||
|
|
||||||
//for (j = 0; j < cv_precipdensity.value; ++j) -- density is 1 for us always
|
|
||||||
{
|
|
||||||
x = basex + ((M_RandomKey(MAPBLOCKUNITS<<3)<<FRACBITS)>>3);
|
x = basex + ((M_RandomKey(MAPBLOCKUNITS<<3)<<FRACBITS)>>3);
|
||||||
y = basey + ((M_RandomKey(MAPBLOCKUNITS<<3)<<FRACBITS)>>3);
|
y = basey + ((M_RandomKey(MAPBLOCKUNITS<<3)<<FRACBITS)>>3);
|
||||||
|
|
||||||
|
@ -9625,7 +9623,7 @@ void P_SpawnPrecipitation(void)
|
||||||
// No sector? Stop wasting time,
|
// No sector? Stop wasting time,
|
||||||
// move on to the next entry in the blockmap
|
// move on to the next entry in the blockmap
|
||||||
if (!precipsector)
|
if (!precipsector)
|
||||||
break;
|
continue;
|
||||||
|
|
||||||
// Exists, but is too small for reasonable precipitation.
|
// Exists, but is too small for reasonable precipitation.
|
||||||
if (!(precipsector->sector->floorheight <= precipsector->sector->ceilingheight - (32<<FRACBITS)))
|
if (!(precipsector->sector->floorheight <= precipsector->sector->ceilingheight - (32<<FRACBITS)))
|
||||||
|
@ -9659,7 +9657,6 @@ void P_SpawnPrecipitation(void)
|
||||||
// Randomly assign a height, now that floorz is set.
|
// Randomly assign a height, now that floorz is set.
|
||||||
rainmo->z = M_RandomRange(rainmo->floorz>>FRACBITS, rainmo->ceilingz>>FRACBITS)<<FRACBITS;
|
rainmo->z = M_RandomRange(rainmo->floorz>>FRACBITS, rainmo->ceilingz>>FRACBITS)<<FRACBITS;
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
if (curWeather == PRECIP_BLANK)
|
if (curWeather == PRECIP_BLANK)
|
||||||
{
|
{
|
||||||
|
|
|
@ -3389,7 +3389,10 @@ static void P_ProcessLineSpecial(line_t *line, mobj_t *mo, sector_t *callsec)
|
||||||
|
|
||||||
// if flags changed, reset sector's light list
|
// if flags changed, reset sector's light list
|
||||||
if (rover->flags != oldflags)
|
if (rover->flags != oldflags)
|
||||||
|
{
|
||||||
sec->moved = true;
|
sec->moved = true;
|
||||||
|
P_RecalcPrecipInSector(sec);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -7878,6 +7881,7 @@ void T_Disappear(disappear_t *d)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
sectors[s].moved = true;
|
sectors[s].moved = true;
|
||||||
|
P_RecalcPrecipInSector(§ors[s]);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (d->exists)
|
if (d->exists)
|
||||||
|
|
Loading…
Reference in a new issue