- replaced getposfromactor

This commit is contained in:
Christoph Oelckers 2022-09-16 18:06:35 +02:00
parent 896c480eb6
commit 0fdc91904d
4 changed files with 4 additions and 10 deletions

View file

@ -1796,7 +1796,7 @@ void movetransports_d(void)
ps[p].transporter_hold = 13;
}
ps[p].getposfromactor(Owner, -gs.playerheight);
ps[p].pos = Owner->spr.pos.plusZ(-gs.playerheight);
ps[p].backupxyz();
ps[p].setbobpos();

View file

@ -1443,7 +1443,7 @@ void movetransports_r(void)
ps[p].transporter_hold = 13;
}
ps[p].getposfromactor(Owner, -gs.playerheight + 4);
ps[p].pos = Owner->spr.pos.plusZ(-gs.playerheight + 4);
ps[p].backupxyz();
ps[p].setbobpos();
@ -2271,7 +2271,7 @@ void rr_specialstats()
if (act2->spr.picnum == RRTILE297)
{
ps[p].angle.ang = act2->spr.angle;
ps[p].getposfromactor(act2, -36);
ps[p].pos = act2->spr.pos.plusZ(-36);
ps[p].backupxyz();
ps[p].setbobpos();
auto pact = ps[p].GetActor();

View file

@ -648,7 +648,7 @@ void resetpspritevars(int g)
ps[j].frag_ps = j;
act->SetOwner(act);
ps[j].getposfromactor(act);
ps[j].pos = act->spr.pos;
ps[j].backupxyz();
ps[j].setbobpos();
act->backuppos();

View file

@ -375,12 +375,6 @@ struct player_struct
{
bobpos = pos.XY();
}
void getposfromactor(DCoreActor* actor, double addz = 0)
{
pos = actor->spr.pos;
if (addz) pos.Z += addz;
}
};
struct Cycler