mirror of
https://github.com/ZDoom/Raze.git
synced 2025-01-18 22:51:50 +00:00
- more cleanup.
This commit is contained in:
parent
ee669a1fec
commit
ef6ba17dfd
5 changed files with 6 additions and 9 deletions
|
@ -322,8 +322,6 @@ void DoShadows(tspriteArray& tsprites, tspritetype* tsp, double viewz)
|
|||
|
||||
// need to find the ground here
|
||||
|
||||
int iloz = loz * zworldtoint;
|
||||
|
||||
// if below or close to sprites z don't bother to draw it
|
||||
if ((viewz - loz) > -8)
|
||||
{
|
||||
|
|
|
@ -67,7 +67,7 @@ Collision MultiClipMove(PLAYER* pp, double zz, double floordist)
|
|||
|
||||
int xvect = vect.X * 16 * worldtoint; // note: this means clipmove input is Q18.14!
|
||||
int yvect = vect.Y * 16 * worldtoint;
|
||||
clipmove(spos, &pp->cursector, xvect, yvect, (int)sop->clipbox_dist[i], Z(4), int(floordist * zworldtoint), CLIPMASK_PLAYER, coll, 1);
|
||||
clipmove(spos, &pp->cursector, xvect, yvect, (int)sop->clipbox_dist[i], 4., floordist, CLIPMASK_PLAYER, coll, 1);
|
||||
|
||||
if (coll.type != kHitNone)
|
||||
{
|
||||
|
@ -98,7 +98,7 @@ Collision MultiClipMove(PLAYER* pp, double zz, double floordist)
|
|||
pos[i].Z = zz;
|
||||
|
||||
// move the box
|
||||
clipmove(pos[i], &pp->cursector, FloatToFixed<18>(pp->vect.X), FloatToFixed<18>(pp->vect.Y), (int)sop->clipbox_dist[i], Z(4), int(floordist * zworldtoint), CLIPMASK_PLAYER, coll);
|
||||
clipmove(pos[i], &pp->cursector, FloatToFixed<18>(pp->vect.X), FloatToFixed<18>(pp->vect.Y), (int)sop->clipbox_dist[i], 4., floordist, CLIPMASK_PLAYER, coll);
|
||||
|
||||
// save the dist moved
|
||||
dist = (pos[i].XY() - opos[i].XY()).Length();
|
||||
|
@ -140,7 +140,7 @@ int MultiClipTurn(PLAYER* pp, DAngle new_ang, double zz, double floordist)
|
|||
DVector2 vect = ang.ToVector() * 1024 * sop->clipbox_vdist[i];
|
||||
Collision coll;
|
||||
|
||||
clipmove(spos, &cursect, FloatToFixed<18>(vect.X), FixedToFloat<18>(vect.Y), (int)sop->clipbox_dist[i], Z(4), int(floordist * zworldtoint), CLIPMASK_PLAYER, coll);
|
||||
clipmove(spos, &cursect, FloatToFixed<18>(vect.X), FixedToFloat<18>(vect.Y), (int)sop->clipbox_dist[i], 4., floordist, CLIPMASK_PLAYER, coll);
|
||||
|
||||
ASSERT(cursect);
|
||||
|
||||
|
|
|
@ -1199,7 +1199,6 @@ DSWActor* DoPickTarget(DSWActor* actor, DAngle max_delta_ang, int skip_targets)
|
|||
DAngle angle2 = VecToAngle(itActor->spr.pos - actor->spr.pos);
|
||||
|
||||
// Get the angle difference
|
||||
// delta_ang = abs(pp->angle.ang.Buildang() - angle2);
|
||||
|
||||
DAngle delta_ang = absangle(angle2, actor->spr.angle);
|
||||
|
||||
|
|
|
@ -940,9 +940,9 @@ int InitRipper2Hang(DSWActor* actor)
|
|||
|
||||
bool Found = false;
|
||||
|
||||
for (int dang = 0; dang < 2048; dang += 128)
|
||||
for (DAngle dang = nullAngle; dang < DAngle360; dang += DAngle22_5)
|
||||
{
|
||||
auto tang = actor->spr.angle + DAngle::fromBuild(dang);
|
||||
auto tang = actor->spr.angle + dang;
|
||||
|
||||
FAFhitscan(actor->spr.pos.plusZ(-ActorSizeZ(actor)), actor->sector(), DVector3(tang.ToVector() * 1024, 0), hit, CLIPMASK_MISSILE);
|
||||
|
||||
|
|
|
@ -6760,7 +6760,6 @@ Collision move_missile(DSWActor* actor, const DVector3& change, double ceil_dist
|
|||
|
||||
Collision move_ground_missile(DSWActor* actor, const DVector2& change, double ceildist, double flordist, uint32_t cliptype, int numtics)
|
||||
{
|
||||
int xchange = change.X * worldtoint, ychange = change.Y * worldtoint;
|
||||
Collision retval{};
|
||||
int ox,oy;
|
||||
|
||||
|
@ -6805,6 +6804,7 @@ Collision move_ground_missile(DSWActor* actor, const DVector2& change, double ce
|
|||
lastsect = dasect;
|
||||
opos = actor->spr.pos;
|
||||
opos.Z = daz;
|
||||
int xchange = change.X * worldtoint, ychange = change.Y * worldtoint;
|
||||
clipmove(opos, &dasect,
|
||||
((xchange * numtics) << 11), ((ychange * numtics) << 11),
|
||||
(((int) actor->spr.clipdist) << 2), ceildist, flordist, cliptype, retval, 1);
|
||||
|
|
Loading…
Reference in a new issue