forked from speed-dreams/speed-dreams-code
Update simplix_sc variable slowdown parameter
Limit side use git-svn-id: https://svn.code.sf.net/p/speed-dreams/code/trunk@5540 30fe4595-0a0c-4342-8851-515496e4dcbd Former-commit-id: 44dec8f3a30be57b5b470caebac54663cd5e1e91 Former-commit-id: 967218f7072e48049a739affef83dcb3eab54e13
This commit is contained in:
parent
794d234aa5
commit
41700a775f
5 changed files with 27 additions and 17 deletions
|
@ -9,10 +9,10 @@
|
|||
//
|
||||
// File : unitdriver.cpp
|
||||
// Created : 2007.11.25
|
||||
// Last changed : 2013.06.13
|
||||
// Last changed : 2013.06.25
|
||||
// Copyright : © 2007-2013 Wolf-Dieter Beelitz
|
||||
// eMail : wdb@wdbee.de
|
||||
// Version : 4.00.001
|
||||
// Version : 4.00.002
|
||||
//--------------------------------------------------------------------------*
|
||||
//
|
||||
// Copyright: (C) 2000 by Eric Espie
|
||||
|
@ -314,6 +314,7 @@ TDriver::TDriver(int Index):
|
|||
oSideReduction(1.0),
|
||||
oLastSideReduction(1.0),
|
||||
oMinDistLong(FLT_MAX),
|
||||
oSlowRadius(1.0),
|
||||
|
||||
NBRRL(0),
|
||||
oRL_FREE(0),
|
||||
|
@ -565,7 +566,7 @@ void TDriver::AdjustDriving(
|
|||
|
||||
Param.oCarParam.oLimitSideUse =
|
||||
GfParmGetNum(Handle,TDriver::SECT_PRIV,PRV_LIMIT_SIDE_USE,NULL,
|
||||
(float) 0) > 0;
|
||||
(float) 1) > 0;
|
||||
if (Param.oCarParam.oLimitSideUse)
|
||||
LogSimplix.debug("#Limit side use: true\n");
|
||||
else
|
||||
|
@ -581,6 +582,11 @@ void TDriver::AdjustDriving(
|
|||
-1.0);
|
||||
LogSimplix.debug("#Ugly CrvZ: %g\n",Param.oCarParam.oUglyCrvZ);
|
||||
|
||||
oSlowRadius =
|
||||
GfParmGetNum(Handle,TDriver::SECT_PRIV,PRV_SLOW_RADIUS,NULL,
|
||||
oSlowRadius);
|
||||
LogSimplix.debug("#Slow Radius: %g\n",oSlowRadius);
|
||||
|
||||
Param.oCarParam.oScaleMu = ScaleMu *
|
||||
GfParmGetNum(Handle,TDriver::SECT_PRIV,PRV_SCALE_MU,NULL,
|
||||
(float) Param.oCarParam.oScaleMu);
|
||||
|
@ -4039,7 +4045,7 @@ double TDriver::CalcCrv_simplix_Identity(double Crv)
|
|||
//--------------------------------------------------------------------------*
|
||||
double TDriver::CalcCrv_simplix_SC(double Crv)
|
||||
{
|
||||
if (fabs(Crv) > 1/50.0)
|
||||
if (fabs(Crv) > 1/oSlowRadius)
|
||||
return 1.5; // Filter narrow turns
|
||||
else
|
||||
return 1.0;
|
||||
|
|
|
@ -9,10 +9,10 @@
|
|||
//
|
||||
// File : unitdriver.h
|
||||
// Created : 2007.11.25
|
||||
// Last changed : 2013.03.03
|
||||
// Last changed : 2013.06.25
|
||||
// Copyright : © 2007-2013 Wolf-Dieter Beelitz
|
||||
// eMail : wdb@wdbee.de
|
||||
// Version : 4.00.000
|
||||
// Version : 4.00.002
|
||||
//--------------------------------------------------------------------------*
|
||||
// Teile dieser Unit basieren auf diversen Header-Dateien von TORCS
|
||||
//
|
||||
|
@ -357,6 +357,7 @@ private:
|
|||
float oLastSideReduction;
|
||||
|
||||
double oMinDistLong;
|
||||
float oSlowRadius;
|
||||
|
||||
int NBRRL;
|
||||
int oRL_FREE;
|
||||
|
|
|
@ -9,10 +9,10 @@
|
|||
//
|
||||
// File : unitglobal.h
|
||||
// Created : 2007.11.17
|
||||
// Last changed : 2013.06.23
|
||||
// Last changed : 2013.06.25
|
||||
// Copyright : © 2007-2013 Wolf-Dieter Beelitz
|
||||
// eMail : wdb@wdbee.de
|
||||
// Version : 4.00.001
|
||||
// Version : 4.00.002
|
||||
//--------------------------------------------------------------------------*
|
||||
// This program was developed and tested on windows XP
|
||||
// There are no known Bugs, but:
|
||||
|
@ -467,6 +467,7 @@ enum
|
|||
#define PRV_SCALE_STEER "scale steer"
|
||||
|
||||
#define PRV_UGLY_CRVZ "ugly crvz" // Use stiff crv
|
||||
#define PRV_SLOW_RADIUS "slow radius" // Radius to start slow down
|
||||
|
||||
#define PRV_SIDE_MU "side mu" // Scale friction calculation for sides
|
||||
#define PRV_RAIN_MU "scale mu rain" // Scale friction calculation for sides
|
||||
|
|
|
@ -7,14 +7,16 @@
|
|||
//
|
||||
// File : unitmain.cpp
|
||||
// Created : 2008.01.27
|
||||
// Last changed : 2013.06.23
|
||||
// Last changed : 2013.06.25
|
||||
// Copyright : © 2007-2013 Wolf-Dieter Beelitz
|
||||
// eMail : wdb@wdbee.de
|
||||
// Version : 4.00.01
|
||||
// Version : 4.00.02
|
||||
//--------------------------------------------------------------------------*
|
||||
// V4.00.001:
|
||||
// V4.00.002:
|
||||
// Modifications for Supercars
|
||||
// Slow down at narrow turns more than normal (Needed for Aalborg)
|
||||
// Individual parameter SlowRadius
|
||||
// Limit side use to inner side to halve of outer side
|
||||
//--------------------------------------------------------------------------*
|
||||
// V4.00.000 (SimuV4)(Single Wheel Braking, Air Brake):
|
||||
// New Logging used
|
||||
|
|
|
@ -10,10 +10,10 @@
|
|||
//
|
||||
// File : unittrack.cpp
|
||||
// Created : 2007.11.17
|
||||
// Last changed : 2013.03.02
|
||||
// Last changed : 2013.06.25
|
||||
// Copyright : © 2007-2011 Wolf-Dieter Beelitz
|
||||
// eMail : wdb@wdbee.de
|
||||
// Version : 4.00.000
|
||||
// Version : 4.00.002
|
||||
//--------------------------------------------------------------------------*
|
||||
// Stellt Funktionen zur Streckenbeschreibung zur Verfügung
|
||||
//--------------------------------------------------------------------------*
|
||||
|
@ -601,9 +601,9 @@ void TTrackDescription::InitTrack
|
|||
}
|
||||
else
|
||||
{
|
||||
WCurb = MIN(WCurb,CarParam.oLimitSideWidth);
|
||||
WCurb = MIN(WCurb,CarParam.oLimitSideWidth/2);
|
||||
W = MIN(W,CarParam.oLimitSideWidth);
|
||||
ExtraW = MIN(ExtraW,CarParam.oLimitSideWidth);
|
||||
ExtraW = MIN(ExtraW,CarParam.oLimitSideWidth/2);
|
||||
}
|
||||
Done = true;
|
||||
}
|
||||
|
@ -618,9 +618,9 @@ void TTrackDescription::InitTrack
|
|||
}
|
||||
else
|
||||
{
|
||||
WCurb = MIN(WCurb,CarParam.oLimitSideWidth);
|
||||
WCurb = MIN(WCurb,CarParam.oLimitSideWidth/2);
|
||||
W = MIN(W,CarParam.oLimitSideWidth);
|
||||
ExtraW = MIN(ExtraW,CarParam.oLimitSideWidth);
|
||||
ExtraW = MIN(ExtraW,CarParam.oLimitSideWidth/2);
|
||||
}
|
||||
Done = true;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue