Car Sleep problem

CmonGirl

13-10-2010 08:23:56

Hi guys. I have one more question about cars.
that my car's initialize function:
NxOgre::RigidBodyDescription description;
description.mMass = 1000;
description.mWakeUpCounter = 1E30;//1e8
mActor = mPhysicsScene->createActor(shapes,Location,description);

This code working. But. Car sleep and dont move when i use break.
for(unsigned int i = 0;i < mWheels.size();i++)
{
if(mWheels[i].mBraking)
mWheels[i].mWheel->setBrakeTorque(Torque);
}

Why may be? Someone help me. :(

betajaen

13-10-2010 09:24:05

Your wake-up counter is ridiculously huge; just use 1E8 and see what happens.

CmonGirl

13-10-2010 10:59:57

Hmm i understand. Car not sleeping. just slowly move. sorry man. :D
thanks for reply.

betajaen

13-10-2010 11:10:15

If it's still moving when you apply the breaks, then the break torque isn't high enough, and like cars you can't just apply the brake once and expect it to stay exactly still, it needs to be on continuously.