Post Reply 
 
Thread Rating:
  • 0 Votes - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Bug in cardynamics.cpp LoadWheel code
07-30-2011, 05:56 PM
Post: #1
Bug in cardynamics.cpp LoadWheel code
Code:
    if (!cfg.get("mass", mass) && !cfg.get("inertia", inertia))
    {
...
        mass = tire_mass + rim_mass;
        inertia = (tire_inertia + rim_inertia) * 4;    // scale inertia fixme
    }
    wheel.SetMass(mass);
    wheel.SetInertia(inertia);        // inertia of associated driveshaft

If the "mass" parameter is present in .car file then second part of the if() statement will not be evaluated and inertia = 0 even if present in .car file.
Find all posts by this user
Quote this message in a reply
07-31-2011, 04:34 AM
Post: #2
 
Fixed, thanks.
Find all posts by this user
Quote this message in a reply
Post Reply 


Forum Jump:


User(s) browsing this thread: 1 Guest(s)