- found one last place where an integer wrapper was called in actor.cpp

This commit is contained in:
Christoph Oelckers 2022-09-26 23:00:52 +02:00
parent 6c98a07a60
commit 298d029d55
2 changed files with 3 additions and 3 deletions

View file

@ -2708,10 +2708,10 @@ static void actNapalmMove(DBloodActor* actor)
actor->ZeroVelocity();
for (int i = 0; i < 2; i++)
{
int t1 = Random(0x33333) + 0x33333;
double t1 = RandomD(3.2) + 3.2;
auto rndang = DAngle::fromBuild(Random2(0x71));
actor->spr.angle = (ang + rndang).Normalized360();
auto spawned = actFireThing(actor, 0, 0, -0x93d0, kThingNapalmBall, t1);
auto spawned = actFireThing(actor, 0., 0., -0.5774, kThingNapalmBall, t1);
spawned->SetOwner(actor->GetOwner());
seqSpawn(61, spawned, nNapalmClient);
spawned->xspr.data4 = spawnparam[i];

View file

@ -548,7 +548,7 @@ inline double RandomF(int a1, int scale = 16)
return FixedToFloat(Random(a1), scale);
}
inline double RandomD(double val, int scale)
inline double RandomD(double val, int scale = 16)
{
return FixedToFloat(Random(FloatToFixed(val, scale)), scale);
}