Duke3d: make actors set to move vertically in CON act as if SFLAG_SMOOTHMOVE was explicitly enabled

This smooths out stuff like octabrains and flying liztroops without making them look stupid when they move on the ground.
This commit is contained in:
Richard Gobeille 2021-11-12 07:53:56 -08:00 committed by Mitchell Richters
parent dcf1c540e6
commit 1389413ca1
2 changed files with 22 additions and 16 deletions

View file

@ -3687,15 +3687,18 @@ void move_d(DDukeActor *actor, int playernum, int xvel)
}
else if (actor->spr.picnum != DRONE && actor->spr.picnum != SHARK && actor->spr.picnum != COMMANDER)
{
if (actor->opos.Z != actor->spr.pos.Z || (ud.multimode < 2 && ud.player_skill < 2))
if (!*(moveptr + 1))
{
if ((actor->temp_data[0] & 1) || ps[playernum].actorsqu == actor) return;
else daxvel <<= 1;
}
else
{
if ((actor->temp_data[0] & 3) || ps[playernum].actorsqu == actor) return;
else daxvel <<= 2;
if (actor->opos.Z != actor->spr.pos.Z || (ud.multimode < 2 && ud.player_skill < 2))
{
if ((actor->temp_data[0] & 1) || ps[playernum].actorsqu == actor) return;
else daxvel <<= 1;
}
else
{
if ((actor->temp_data[0] & 3) || ps[playernum].actorsqu == actor) return;
else daxvel <<= 2;
}
}
}
}

View file

@ -3716,15 +3716,18 @@ void move_r(DDukeActor *actor, int pnum, int xvel)
(!isRRRA() && actor->spr.picnum != DRONE && actor->spr.picnum != SHARK && actor->spr.picnum != UFO1_RR
&& actor->spr.picnum != UFO2 && actor->spr.picnum != UFO3 && actor->spr.picnum != UFO4 && actor->spr.picnum != UFO5))
{
if (actor->opos.Z != actor->spr.pos.Z || (ud.multimode < 2 && ud.player_skill < 2))
if (!*(moveptr + 1))
{
if ((actor->temp_data[0] & 1) || ps[pnum].actorsqu == actor) return;
else daxvel <<= 1;
}
else
{
if ((actor->temp_data[0] & 3) || ps[pnum].actorsqu == actor) return;
else daxvel <<= 2;
if (actor->opos.Z != actor->spr.pos.Z || (ud.multimode < 2 && ud.player_skill < 2))
{
if ((actor->temp_data[0] & 1) || ps[pnum].actorsqu == actor) return;
else daxvel <<= 1;
}
else
{
if ((actor->temp_data[0] & 3) || ps[pnum].actorsqu == actor) return;
else daxvel <<= 2;
}
}
}
}