mirror of
https://github.com/ZDoom/Raze.git
synced 2024-11-15 17:01:28 +00:00
- partial floatification of movesprite
This commit is contained in:
parent
33a3a36da1
commit
93fd94ecbb
1 changed files with 5 additions and 7 deletions
|
@ -490,9 +490,7 @@ Collision movesprite(DExhumedActor* pActor, int dx, int dy, int dz, int ceildist
|
|||
{
|
||||
bTouchFloor = false;
|
||||
|
||||
int x = pActor->int_pos().X;
|
||||
int y = pActor->int_pos().Y;
|
||||
int z = pActor->int_pos().Z;
|
||||
auto spos = pActor->spr.pos;
|
||||
|
||||
int nSpriteHeight = GetActorHeight(pActor);
|
||||
|
||||
|
@ -501,9 +499,9 @@ Collision movesprite(DExhumedActor* pActor, int dx, int dy, int dz, int ceildist
|
|||
auto pSector = pActor->sector();
|
||||
assert(pSector);
|
||||
|
||||
int floorZ = pSector->int_floorz();
|
||||
double floorZ = pSector->floorz;
|
||||
|
||||
if ((pSector->Flag & kSectUnderwater) || (floorZ < z))
|
||||
if ((pSector->Flag & kSectUnderwater) || (floorZ < spos.Z))
|
||||
{
|
||||
dx >>= 1;
|
||||
dy >>= 1;
|
||||
|
@ -552,9 +550,9 @@ Collision movesprite(DExhumedActor* pActor, int dx, int dy, int dz, int ceildist
|
|||
dz = 0;
|
||||
}
|
||||
|
||||
if ((pSector->int_floorz() - z) < (dz + flordist))
|
||||
if ((pSector->floorz - spos.Z) < (dz + flordist) * zinttoworld)
|
||||
{
|
||||
pActor->set_int_xy( x, y);
|
||||
pActor->spr.pos.XY() = spos.XY();
|
||||
}
|
||||
else
|
||||
{
|
||||
|
|
Loading…
Reference in a new issue