mirror of
https://github.com/ZDoom/Raze.git
synced 2024-11-15 08:51:24 +00:00
- get rid of vel wrappers for nnext conditions.
The fixed point conversion here is unavoidable, so make it explcit.
This commit is contained in:
parent
5dc2d467ee
commit
049220239c
2 changed files with 11 additions and 11 deletions
|
@ -368,7 +368,7 @@ void EnemyBubble(DBloodActor* actor, sectortype*) // 11
|
|||
if (!actor) return;
|
||||
double top, bottom;
|
||||
GetActorExtents(actor, &top, &bottom);
|
||||
for (int i = 0; i < (abs(actor->int_vel().Z) >> 18); i++)
|
||||
for (int i = 0; i < int(abs(actor->vel.Z) * 0.25); i++)
|
||||
{
|
||||
auto nAngle = RandomAngle();
|
||||
double nDist = (actor->spr.xrepeat * tileWidth(actor->spr.picnum)) * (REPEAT_SCALE / 2);
|
||||
|
|
|
@ -4601,18 +4601,18 @@ bool condCheckSprite(DBloodActor* aCond, int cmpOp, bool PUSH)
|
|||
{
|
||||
if (arg1 == 0)
|
||||
{
|
||||
if ((var = condCmp(objActor->int_vel().X, arg1, arg2, cmpOp)) == true) return var;
|
||||
if ((var = condCmp(objActor->int_vel().Y, arg1, arg2, cmpOp)) == true) return var;
|
||||
if ((var = condCmp(objActor->int_vel().Z, arg1, arg2, cmpOp)) == true) return var;
|
||||
if ((var = condCmp(FloatToFixed(objActor->vel.X), arg1, arg2, cmpOp)) == true) return var;
|
||||
if ((var = condCmp(FloatToFixed(objActor->vel.Y), arg1, arg2, cmpOp)) == true) return var;
|
||||
if ((var = condCmp(FloatToFixed(objActor->vel.Z), arg1, arg2, cmpOp)) == true) return var;
|
||||
}
|
||||
else if (arg1 == 1) return condCmp(objActor->int_vel().X, arg1, arg2, cmpOp);
|
||||
else if (arg1 == 2) return condCmp(objActor->int_vel().Y, arg1, arg2, cmpOp);
|
||||
else if (arg1 == 3) return condCmp(objActor->int_vel().Z, arg1, arg2, cmpOp);
|
||||
else if (arg1 == 1) return condCmp(FloatToFixed(objActor->vel.X), arg1, arg2, cmpOp);
|
||||
else if (arg1 == 2) return condCmp(FloatToFixed(objActor->vel.Y), arg1, arg2, cmpOp);
|
||||
else if (arg1 == 3) return condCmp(FloatToFixed(objActor->vel.Z), arg1, arg2, cmpOp);
|
||||
}
|
||||
else if (arg1 == 0) return (objActor->vel.X != 0 || objActor->vel.Y != 0 || objActor->int_vel().Z);
|
||||
else if (arg1 == 1) return (objActor->int_vel().X);
|
||||
else if (arg1 == 2) return (objActor->int_vel().Y);
|
||||
else if (arg1 == 3) return (objActor->int_vel().Z);
|
||||
else if (arg1 == 0) return (!objActor->vel.isZero());
|
||||
else if (arg1 == 1) return (FloatToFixed(objActor->vel.X));
|
||||
else if (arg1 == 2) return (FloatToFixed(objActor->vel.Y));
|
||||
else if (arg1 == 3) return (FloatToFixed(objActor->vel.Z));
|
||||
break;
|
||||
case 30:
|
||||
if (!spriteIsUnderwater(objActor) && !spriteIsUnderwater(objActor, true)) return false;
|
||||
|
|
Loading…
Reference in a new issue