mirror of
https://github.com/DrBeef/Raze.git
synced 2024-11-15 17:01:51 +00:00
- floatify pos in movesprite_ex_d
This commit is contained in:
parent
2895e8ac05
commit
ae0640b1ca
1 changed files with 7 additions and 7 deletions
|
@ -449,13 +449,13 @@ int movesprite_ex_d(DDukeActor* actor, int xchange, int ychange, int zchange, un
|
|||
|
||||
auto dasectp = actor->sector();
|
||||
|
||||
vec3_t pos = actor->int_pos();
|
||||
pos.Z -= ((tileHeight(actor->spr.picnum) * actor->spr.yrepeat) << 1);
|
||||
auto ppos = actor->spr.pos;
|
||||
ppos.Z -= (tileHeight(actor->spr.picnum) * actor->spr.yrepeat) * REPEAT_SCALE * 0.5;
|
||||
|
||||
if (bg)
|
||||
{
|
||||
if (actor->spr.xrepeat > 60)
|
||||
clipmove(pos, &dasectp, ((xchange * TICSPERFRAME) << 11), ((ychange * TICSPERFRAME) << 11), 1024, (4 << 8), (4 << 8), cliptype, result);
|
||||
clipmove(ppos, &dasectp, ((xchange * TICSPERFRAME) << 11), ((ychange * TICSPERFRAME) << 11), 1024, (4 << 8), (4 << 8), cliptype, result);
|
||||
else
|
||||
{
|
||||
if (actor->spr.picnum == LIZMAN)
|
||||
|
@ -465,7 +465,7 @@ int movesprite_ex_d(DDukeActor* actor, int xchange, int ychange, int zchange, un
|
|||
else
|
||||
clipdist = 192;
|
||||
|
||||
clipmove(pos, &dasectp, ((xchange * TICSPERFRAME) << 11), ((ychange * TICSPERFRAME) << 11), clipdist, (4 << 8), (4 << 8), cliptype, result);
|
||||
clipmove(ppos, &dasectp, ((xchange * TICSPERFRAME) << 11), ((ychange * TICSPERFRAME) << 11), clipdist, (4 << 8), (4 << 8), cliptype, result);
|
||||
}
|
||||
|
||||
// conditional code from hell...
|
||||
|
@ -490,11 +490,11 @@ int movesprite_ex_d(DDukeActor* actor, int xchange, int ychange, int zchange, un
|
|||
else
|
||||
{
|
||||
if (actor->spr.statnum == STAT_PROJECTILE)
|
||||
clipmove(pos, &dasectp, ((xchange * TICSPERFRAME) << 11), ((ychange * TICSPERFRAME) << 11), 8, (4 << 8), (4 << 8), cliptype, result);
|
||||
clipmove(ppos, &dasectp, ((xchange * TICSPERFRAME) << 11), ((ychange * TICSPERFRAME) << 11), 8, (4 << 8), (4 << 8), cliptype, result);
|
||||
else
|
||||
clipmove(pos, &dasectp, ((xchange * TICSPERFRAME) << 11), ((ychange * TICSPERFRAME) << 11), (int)(actor->spr.clipdist << 2), (4 << 8), (4 << 8), cliptype, result);
|
||||
clipmove(ppos, &dasectp, ((xchange * TICSPERFRAME) << 11), ((ychange * TICSPERFRAME) << 11), (int)(actor->spr.clipdist << 2), (4 << 8), (4 << 8), cliptype, result);
|
||||
}
|
||||
actor->set_int_xy(pos.X, pos.Y);
|
||||
actor->spr.pos.XY() = ppos.XY();
|
||||
|
||||
if (dasectp != nullptr && dasectp != actor->sector())
|
||||
ChangeActorSect(actor, dasectp);
|
||||
|
|
Loading…
Reference in a new issue