[BloodyMess1.5.5] Car problem

Oceax

25-07-2009 00:17:37

Im trying to get a car working like the exampel in the 1.5.5 blog thread
http://www.ogre3d.org/addonforums/viewtopic.php?f=6&t=10348&start=0&hilit=simulate

My code is exactly as in that thread with mass set, wakeup set, etc. mDriving is "true" for front wheels.
Graphics looks correct and i can steer the wheels but they dont rotate when the following function is called.

void WheeledObject::drive(float torque)
{
for (unsigned int i=0;i < mWheels.size();i++)
if (mWheels[i].mDriving)
{
mWheels[i].mWheel->setMotorTorque(torque);
}
}


Any ideas what can be wrong?

Oceax

26-07-2009 23:34:20

I solved the problem with the wheels not rotating but now i got a problem with the graphics, when the wheels rotate they vary between being black and normal. Its like the wheels dont have light on them.

A video showing the problem: http://www.youtube.com/watch?v=BlMThYisPT0