mirror of
https://github.com/DrBeef/Raze.git
synced 2025-02-22 03:31:26 +00:00
- got rid of int_clipdist.
This commit is contained in:
parent
29eb729cd3
commit
4af1461ec3
3 changed files with 3 additions and 8 deletions
|
@ -478,10 +478,11 @@ CollisionBase clipmove_(vec3_t * const pos, int * const sectnum, int32_t xvect,
|
||||||
|
|
||||||
if (pos->Z > daz-height-flordist && pos->Z < daz+ceildist)
|
if (pos->Z > daz-height-flordist && pos->Z < daz+ceildist)
|
||||||
{
|
{
|
||||||
int32_t bsz = (actor->int_clipdist())+walldist;
|
int cd = actor->fClipdist() * worldtoint;
|
||||||
|
int32_t bsz = cd + walldist;
|
||||||
if (diff.X < 0) bsz = -bsz;
|
if (diff.X < 0) bsz = -bsz;
|
||||||
addclipline(p1.X-bsz, p1.Y-bsz, p1.X-bsz, p1.Y+bsz, obj, false);
|
addclipline(p1.X-bsz, p1.Y-bsz, p1.X-bsz, p1.Y+bsz, obj, false);
|
||||||
bsz = (actor->int_clipdist())+walldist;
|
bsz = cd + walldist;
|
||||||
if (diff.Y < 0) bsz = -bsz;
|
if (diff.Y < 0) bsz = -bsz;
|
||||||
addclipline(p1.X+bsz, p1.Y-bsz, p1.X-bsz, p1.Y-bsz, obj, false);
|
addclipline(p1.X+bsz, p1.Y-bsz, p1.X-bsz, p1.Y-bsz, obj, false);
|
||||||
}
|
}
|
||||||
|
|
|
@ -165,11 +165,6 @@ public:
|
||||||
return spr. clipdist * 0.25;
|
return spr. clipdist * 0.25;
|
||||||
}
|
}
|
||||||
|
|
||||||
int int_clipdist()
|
|
||||||
{
|
|
||||||
return spr. clipdist << 2;
|
|
||||||
}
|
|
||||||
|
|
||||||
void set_native_clipdist(int val)
|
void set_native_clipdist(int val)
|
||||||
{
|
{
|
||||||
spr. clipdist = val;
|
spr. clipdist = val;
|
||||||
|
|
|
@ -742,7 +742,6 @@ void viewDrawScreen(bool sceneonly)
|
||||||
pPlayer->actor->spr.cstat = bakCstat;
|
pPlayer->actor->spr.cstat = bakCstat;
|
||||||
bDeliriumOld = bDelirium && gDeliriumBlur;
|
bDeliriumOld = bDelirium && gDeliriumBlur;
|
||||||
|
|
||||||
int nClipDist = pPlayer->actor->int_clipdist();
|
|
||||||
if (sceneonly) return;
|
if (sceneonly) return;
|
||||||
double look_anghalf = pPlayer->angle.look_anghalf(interpfrac);
|
double look_anghalf = pPlayer->angle.look_anghalf(interpfrac);
|
||||||
DrawCrosshair(kCrosshairTile, pPlayer->actor->xspr.health >> 4, -look_anghalf, 0, 2);
|
DrawCrosshair(kCrosshairTile, pPlayer->actor->xspr.health >> 4, -look_anghalf, 0, 2);
|
||||||
|
|
Loading…
Reference in a new issue