1
0
mirror of https://foundry.openuru.org/gitblit/r/CWE-ou-minkata.git synced 2025-07-20 04:09:16 +00:00

Eliminate hsScalar and hsFixed

Modern CPUs support floats just fine... hsFixed was crazy.
This commit is contained in:
2012-01-21 02:03:37 -05:00
parent 5027b5a4ac
commit e020651e4b
584 changed files with 5401 additions and 6399 deletions

View File

@ -64,7 +64,7 @@ plAvBrainDrive::plAvBrainDrive()
}
// CTOR max velocity, turn rate
plAvBrainDrive::plAvBrainDrive(hsScalar maxVelocity, hsScalar turnRate)
plAvBrainDrive::plAvBrainDrive(float maxVelocity, float turnRate)
: fMaxVelocity(maxVelocity), fTurnRate(turnRate)
{
}
@ -100,17 +100,17 @@ void plAvBrainDrive::IEnablePhysics(bool enable, plKey avKey)
}
// APPLY
hsBool plAvBrainDrive::Apply(double timeNow, hsScalar elapsed)
hsBool plAvBrainDrive::Apply(double timeNow, float elapsed)
{
plSceneObject * avSO = fAvMod->GetTarget(0);
hsScalar eTime = hsTimer::GetDelSysSeconds();
float eTime = hsTimer::GetDelSysSeconds();
hsMatrix44 targetMatrix = avSO->GetLocalToWorld();
hsPoint3 playerPos = targetMatrix.GetTranslate();
hsVector3 view, up, right;
targetMatrix.GetAxis(&view, &up, &right);
hsScalar speed = fMaxVelocity;
hsScalar turn = fTurnRate;
float speed = fMaxVelocity;
float turn = fTurnRate;
if (fAvMod->FastKeyDown())
{
@ -148,7 +148,7 @@ hsBool plAvBrainDrive::Apply(double timeNow, hsScalar elapsed)
hsVector3 rotUp(0,0,1);
hsVector3 rotRight(1,0,0);
hsMatrix44 rot;
hsScalar angle = 0;
float angle = 0;
if ( fAvMod->GetInputFlag( B_CONTROL_ROTATE_RIGHT ) || fAvMod->GetInputFlag( B_CONTROL_ROTATE_LEFT ) || fAvMod->GetInputFlag( A_CONTROL_TURN ) )
{