mirror of
https://github.com/DrBeef/Raze.git
synced 2025-02-21 11:11:16 +00:00
- another set of simple changes.
This commit is contained in:
parent
efb538ba69
commit
c41af213b4
6 changed files with 10 additions and 11 deletions
|
@ -726,7 +726,7 @@ extern FreeListArray<Snake, kMaxSnakes> SnakeList;
|
|||
|
||||
void InitSnakes();
|
||||
int GrabSnake();
|
||||
void BuildSnake(int nPlayer, int zVal);
|
||||
void BuildSnake(int nPlayer, double zVal);
|
||||
void FuncSnake(int, int, int, int);
|
||||
|
||||
// spider
|
||||
|
|
|
@ -809,7 +809,7 @@ loc_flag:
|
|||
}
|
||||
case kWeaponStaff:
|
||||
{
|
||||
BuildSnake(nPlayer, nHeight * zworldtoint);
|
||||
BuildSnake(nPlayer, nHeight);
|
||||
nQuake[nPlayer] = 2.;
|
||||
|
||||
PlayerList[nPlayer].nThrust -= pPlayerActor->spr.angle.ToVector() * 2;
|
||||
|
|
|
@ -213,7 +213,7 @@ int BelowNear(DExhumedActor* pActor, double walldist)
|
|||
}
|
||||
}
|
||||
|
||||
Collision movespritez(DExhumedActor* pActor, double z, double height, int clipdist)
|
||||
Collision movespritez(DExhumedActor* pActor, double z, double height, double clipdist)
|
||||
{
|
||||
auto pSector = pActor->sector();
|
||||
assert(pSector);
|
||||
|
@ -376,7 +376,7 @@ Collision movespritez(DExhumedActor* pActor, double z, double height, int clipdi
|
|||
|
||||
if (pActor->spr.statnum == 100)
|
||||
{
|
||||
nRet.exbits |= BelowNear(pActor, clipdist * (inttoworld * 1.5));
|
||||
nRet.exbits |= BelowNear(pActor, clipdist * 1.5);
|
||||
}
|
||||
|
||||
return nRet;
|
||||
|
@ -401,7 +401,6 @@ Collision movesprite(DExhumedActor* pActor, int dx, int dy, int dz, int ceildist
|
|||
|
||||
auto spos = pActor->spr.pos;
|
||||
double nSpriteHeight = GetActorHeight(pActor);
|
||||
int nClipDist = pActor->int_clipdist();
|
||||
auto pSector = pActor->sector();
|
||||
assert(pSector);
|
||||
|
||||
|
@ -412,7 +411,7 @@ Collision movesprite(DExhumedActor* pActor, int dx, int dy, int dz, int ceildist
|
|||
vect *= 0.5;
|
||||
}
|
||||
|
||||
Collision nRet = movespritez(pActor, dz * zinttoworld, nSpriteHeight, nClipDist);
|
||||
Collision nRet = movespritez(pActor, dz * zinttoworld, nSpriteHeight, pActor->fClipdist());
|
||||
|
||||
pSector = pActor->sector(); // modified in movespritez so re-grab this variable
|
||||
|
||||
|
@ -435,7 +434,7 @@ Collision movesprite(DExhumedActor* pActor, int dx, int dy, int dz, int ceildist
|
|||
}
|
||||
|
||||
Collision coll;
|
||||
clipmove(pActor->spr.pos, &pSector, FloatToFixed<18>(vect.X), FloatToFixed<18>(vect.Y), nClipDist, int(nSpriteHeight * zworldtoint), flordist, clipmask, coll);
|
||||
clipmove(pActor->spr.pos, &pSector, FloatToFixed<18>(vect.X), FloatToFixed<18>(vect.Y), pActor->int_clipdist(), int(nSpriteHeight * zworldtoint), flordist, clipmask, coll);
|
||||
if (coll.type != kHitNone) // originally this or'ed the two values which can create unpredictable bad values in some edge cases.
|
||||
{
|
||||
coll.exbits = nRet.exbits;
|
||||
|
|
|
@ -124,9 +124,9 @@ void ExplodeSnakeSprite(DExhumedActor* pActor, int nPlayer)
|
|||
StopActorSound(pActor);
|
||||
}
|
||||
|
||||
void BuildSnake(int nPlayer, int zVal_)
|
||||
void BuildSnake(int nPlayer, double zVal)
|
||||
{
|
||||
double zVal = zVal_ * zinttoworld - 5;
|
||||
zVal -= 5;
|
||||
|
||||
auto pPlayerActor = PlayerList[nPlayer].pActor;
|
||||
auto pViewSect = PlayerList[nPlayer].pPlayerViewSect;
|
||||
|
|
|
@ -100,7 +100,7 @@ static void analyzesprites(tspriteArray& tsprites, const DVector3& view, double
|
|||
if ((pTSprite->picnum == kTorch1 || pTSprite->picnum == kTorch2) && (pTSprite->cstat & CSTAT_SPRITE_YCENTER) == 0)
|
||||
{
|
||||
pTSprite->cstat |= CSTAT_SPRITE_YCENTER;
|
||||
double nTileY = (tileHeight(pTSprite->picnum) * pTSprite->yrepeat) * 2 * zinttoworld;
|
||||
double nTileY = (tileHeight(pTSprite->picnum) * pTSprite->yrepeat) * REPEAT_SCALE * 0.5;
|
||||
pTSprite->pos.Z -= nTileY;
|
||||
}
|
||||
|
||||
|
|
|
@ -225,7 +225,7 @@ void AIWasp::Tick(RunListEvent* ev)
|
|||
|
||||
case 0:
|
||||
{
|
||||
pActor->set_int_zvel(bsin(pActor->nAngle, -4));
|
||||
pActor->vel.Z = BobVal(pActor->nAngle) * 4;
|
||||
|
||||
pActor->nAngle += pActor->nAngle2;
|
||||
pActor->nAngle &= kAngleMask;
|
||||
|
|
Loading…
Reference in a new issue