Back to the Vavoom Forum Archives
Crimson Wizard
Karnizero
Crimson Wizard
Karnizero
Crimson Wizard
Crimson Wizard
...
if (mthing)
{
...
if (bFloatBob || bFixedFloatZ /* [CW] */)
{
// Seed random starting index for bobbing motion
FloatBobPhase = Random() * 256.0 / 35.0;
Special1f = mthing->height;
}
}
Physics:
...
if (!bFloatBob && !bFixedFloatZ)
{
UpdateVelocity();
}
...
if (bFloatBob && bSpecial)
{
....
}
else if (bFixedFloatZ /* [CW] here it goes */)
{
if (Sector->bHasExtrafloors)
{
// Make sure FloorZ is from bottom region.
Origin.z = ONFLOORZ;
LinkToWorld();
}
Origin.z = FloorZ + Special1f;
}
Karnizero
Crimson Wizard