mirror of
https://github.com/ZDoom/Raze.git
synced 2025-03-13 12:32:13 +00:00
- renamed variables in handle_se08
This commit is contained in:
parent
845287a7ba
commit
b62c081d37
1 changed files with 17 additions and 17 deletions
|
@ -3368,7 +3368,7 @@ void handle_se08(DDukeActor *actor, bool checkhitag1)
|
||||||
int st = actor->spr.lotag;
|
int st = actor->spr.lotag;
|
||||||
int sh = actor->spr.hitag;
|
int sh = actor->spr.hitag;
|
||||||
|
|
||||||
int x, j = -1;
|
int change, goal = -1;
|
||||||
|
|
||||||
if (actor->temp_data[4])
|
if (actor->temp_data[4])
|
||||||
{
|
{
|
||||||
|
@ -3378,18 +3378,18 @@ void handle_se08(DDukeActor *actor, bool checkhitag1)
|
||||||
deletesprite(actor);
|
deletesprite(actor);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
j = 1;
|
goal = 1;
|
||||||
}
|
}
|
||||||
else j = getanimationgoal(anim_ceilingz, actor->sector());
|
else goal = getanimationgoal(anim_ceilingz, actor->sector());
|
||||||
|
|
||||||
if (j >= 0)
|
if (goal >= 0)
|
||||||
{
|
{
|
||||||
if ((sc->lotag & 0x8000) || actor->temp_data[4])
|
if ((sc->lotag & 0x8000) || actor->temp_data[4])
|
||||||
x = -actor->temp_data[3];
|
change = -actor->temp_data[3];
|
||||||
else
|
else
|
||||||
x = actor->temp_data[3];
|
change = actor->temp_data[3];
|
||||||
|
|
||||||
if (st == 9) x = -x;
|
if (st == 9) change = -change;
|
||||||
|
|
||||||
DukeStatIterator it(STAT_EFFECTOR);
|
DukeStatIterator it(STAT_EFFECTOR);
|
||||||
while (auto ac = it.Next())
|
while (auto ac = it.Next())
|
||||||
|
@ -3397,16 +3397,16 @@ void handle_se08(DDukeActor *actor, bool checkhitag1)
|
||||||
if (((ac->spr.lotag) == st) && (ac->spr.hitag) == sh)
|
if (((ac->spr.lotag) == st) && (ac->spr.hitag) == sh)
|
||||||
{
|
{
|
||||||
auto sect = ac->sector();
|
auto sect = ac->sector();
|
||||||
int m = ac->spr.shade;
|
int minshade = ac->spr.shade;
|
||||||
|
|
||||||
for (auto& wal : wallsofsector(sect))
|
for (auto& wal : wallsofsector(sect))
|
||||||
{
|
{
|
||||||
if (wal.hitag != 1)
|
if (wal.hitag != 1)
|
||||||
{
|
{
|
||||||
wal.shade += x;
|
wal.shade += change;
|
||||||
|
|
||||||
if (wal.shade < m)
|
if (wal.shade < minshade)
|
||||||
wal.shade = m;
|
wal.shade = minshade;
|
||||||
else if (wal.shade > ac->temp_data[2])
|
else if (wal.shade > ac->temp_data[2])
|
||||||
wal.shade = ac->temp_data[2];
|
wal.shade = ac->temp_data[2];
|
||||||
|
|
||||||
|
@ -3416,16 +3416,16 @@ void handle_se08(DDukeActor *actor, bool checkhitag1)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
sect->floorshade += x;
|
sect->floorshade += change;
|
||||||
sect->ceilingshade += x;
|
sect->ceilingshade += change;
|
||||||
|
|
||||||
if (sect->floorshade < m)
|
if (sect->floorshade < minshade)
|
||||||
sect->floorshade = m;
|
sect->floorshade = minshade;
|
||||||
else if (sect->floorshade > ac->temp_data[0])
|
else if (sect->floorshade > ac->temp_data[0])
|
||||||
sect->floorshade = ac->temp_data[0];
|
sect->floorshade = ac->temp_data[0];
|
||||||
|
|
||||||
if (sect->ceilingshade < m)
|
if (sect->ceilingshade < minshade)
|
||||||
sect->ceilingshade = m;
|
sect->ceilingshade = minshade;
|
||||||
else if (sect->ceilingshade > ac->temp_data[1])
|
else if (sect->ceilingshade > ac->temp_data[1])
|
||||||
sect->ceilingshade = ac->temp_data[1];
|
sect->ceilingshade = ac->temp_data[1];
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue