672 cross hair steering and braking fixes
git-svn-id: https://svn.code.sf.net/p/speed-dreams/code/trunk@4688 30fe4595-0a0c-4342-8851-515496e4dcbd Former-commit-id: cd42c527c1da2b541dea4cb5a6de92aa436e2939 Former-commit-id: 72148949d007db13938f6a82cf3c9ffac7ed0405
This commit is contained in:
parent
772f029554
commit
65f372ce35
1 changed files with 3 additions and 3 deletions
|
@ -261,7 +261,7 @@ cGrBoard::grDispGGraph(tCarElt *car)
|
|||
// a) Detect wheel blocking, and change current color to red if so.
|
||||
for (int xx = 0; xx < 4; ++xx)
|
||||
{
|
||||
if (car->_wheelSpinVel(xx) < car->_speed_x - 5.0f)
|
||||
if (fabs(car->_speed_x) - fabs(car->_wheelSpinVel(xx) * car->_wheelRadius(xx)) > 5.0f)
|
||||
{
|
||||
glColor4f(1.0, 0.0, 0.0, 1.0);
|
||||
break;
|
||||
|
@ -282,8 +282,8 @@ cGrBoard::grDispGGraph(tCarElt *car)
|
|||
// length proportional to the steer command).
|
||||
glVertex2f(X1, Y1 - THNSS);
|
||||
glVertex2f(X1, Y1 + THNSS);
|
||||
glVertex2f(X1 - car->ctrl.steer * 100.0f, Y1 + THNSS);
|
||||
glVertex2f(X1 - car->ctrl.steer * 100.0f, Y1 - THNSS);
|
||||
glVertex2f(X1 - car->ctrl.steer * 50.0f, Y1 + THNSS);
|
||||
glVertex2f(X1 - car->ctrl.steer * 50.0f, Y1 - THNSS);
|
||||
|
||||
// Draw the clutch gauge (vertical thick segment, starting in xc, yc,
|
||||
// going upwards, length proportional to the clutch command).
|
||||
|
|
Loading…
Reference in a new issue