Skip to content

Commit ee45324

Browse files
committed
Further hiding
1 parent 86d38a2 commit ee45324

File tree

1 file changed

+3
-0
lines changed
  • Source/Orts.Simulation/Simulation/RollingStocks/SubSystems/PowerTransmissions

1 file changed

+3
-0
lines changed

Source/Orts.Simulation/Simulation/RollingStocks/SubSystems/PowerTransmissions/Axle.cs

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1100,6 +1100,7 @@ public void Save(BinaryWriter outf)
11001100
/// </summary>
11011101
public (double accelMpSS, double angSpeedRadpS, double driveForceN, double axleMotiveForceN, double axleBrakeForceN, double axleFrictionForceN) GetAxleMotionVariation(double axleSpeedMpS, double elapsedClockSeconds)
11021102
{
1103+
if (double.IsNaN(axleSpeedMpS)) axleSpeedMpS = 0;
11031104
double slipSpeedMpS = axleSpeedMpS - TrainSpeedMpS;
11041105
// Compute force transmitted to rail according to adhesion curves
11051106
double axleOutForceN;
@@ -1325,12 +1326,14 @@ public virtual void Update(float elapsedSeconds)
13251326
WheelAdhesion = (float)SlipCharacteristicsPolach(SlipSpeedMpS);
13261327
MaximumWheelAdhesion = (float)SlipCharacteristicsPolach(WheelSlipThresholdMpS);
13271328

1329+
#if DEBUG_ADHESION
13281330
if (count < 6 && count++ == 5)
13291331
{
13301332
TrainSpeedMpS = 10 / 3.6f;
13311333
Polach.Update();
13321334
axleStaticForceN = AxleWeightN * SlipCharacteristicsPolach(0);
13331335
}
1336+
#endif
13341337
}
13351338
else
13361339
{

0 commit comments

Comments
 (0)