@@ -916,7 +916,7 @@ public void UpdateTripleValveState(float elapsedClockSeconds)
916
916
}
917
917
TripleValveState = ValveState . Release ;
918
918
}
919
- else if ( TripleValveState != ValveState . Emergency )
919
+ else if ( TripleValveState != ValveState . Emergency || ( TripleValveState == ValveState . Emergency && BrakeLine1PressurePSI > AuxResPressurePSI ) )
920
920
{
921
921
TripleValveState = ValveState . Lap ;
922
922
}
@@ -1040,8 +1040,10 @@ public override void Update(float elapsedClockSeconds)
1040
1040
1041
1041
if ( threshold < InitialApplicationThresholdPSI * AuxCylVolumeRatio ) // Prevent brakes getting stuck with a small amount of air on distributor systems
1042
1042
threshold = 0 ;
1043
- if ( MRPAuxResCharging && HighSpeedReducingPressurePSI > 0 && threshold > HighSpeedReducingPressurePSI )
1044
- threshold = HighSpeedReducingPressurePSI ; // Small workaround to improve compatibility between modern systems and HSRV (such systems shouldn't have an HSRV equipped)
1043
+ // Prevent air from being perpetually vented by the HSRV in graduated release systems
1044
+ if ( HighSpeedReducingPressurePSI > 0 && threshold > HighSpeedReducingPressurePSI
1045
+ && ( ( MRPAuxResCharging && ! ( Car as MSTSWagon ) . SupplyReservoirPresent ) || BrakeLine1PressurePSI > AuxResPressurePSI ) )
1046
+ threshold = HighSpeedReducingPressurePSI ;
1045
1047
}
1046
1048
else
1047
1049
{
@@ -1133,7 +1135,7 @@ public override void Update(float elapsedClockSeconds)
1133
1135
// Amount of air vented is proportional to pressure reduction from external sources
1134
1136
dpPipe = MathHelper . Clamp ( - SmoothedBrakePipeChangePSIpS . SmoothedValue * AcceleratedApplicationFactor , 0 , AcceleratedApplicationLimitPSIpS ) * elapsedClockSeconds ;
1135
1137
}
1136
- if ( TripleValveState == ValveState . Emergency && ! QuickActionFitted )
1138
+ if ( TripleValveState == ValveState . Emergency && ( ! QuickActionFitted || BrakeLine1PressurePSI < AutoCylPressurePSI ) )
1137
1139
dp = elapsedClockSeconds * MaxApplicationRatePSIpS ;
1138
1140
else
1139
1141
dp = elapsedClockSeconds * ServiceApplicationRatePSIpS ;
0 commit comments