You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Automatic merge of T1.5.1-1004-g6fd841761e and 19 pull requests
- Pull request #799 at dfc715e: Consolidated wind simulation
- Pull request #839 at d00beb9: First phase of https://blueprints.launchpad.net/or/+spec/additional-cruise-control-parameters
- Pull request #876 at f92de76: docs: add source for documents previously on website to source Documentation folder
- Pull request #882 at 8f695a4: Blueprint/train car operations UI window
- Pull request #885 at 2728d6d: feat: Add notifications to Menu
- Pull request #891 at 9a1d6b2: Auto save
- Pull request #892 at 1f5ba4c: Signal Function OPP_SIG_ID_TRAINPATH
- Pull request #896 at 5866028: First implementation of https://blueprints.launchpad.net/or/+spec/specific-sounds-for-ai-trains
- Pull request #900 at c27f32d: DMI updates
- Pull request #903 at 3e390b8: Downloading route content (Github, zip)
- Pull request #912 at 359cfee: New Triple Valve Features Vol. 2
- Pull request #922 at 0d3e70b: Autopilot for timetable mode
- Pull request #946 at 66f836c: Advanced track sounds
- Pull request #949 at 0306d75: Oil Burning Locomotive
- Pull request #952 at b2af1f5: Investigation - Pulsing graphics part 1
- Pull request #953 at a519452: Fix Lights Crash on Corrupt Shapes
- Pull request #954 at 84c2f4b: Add Support for Multiple Track Profiles
- Pull request #956 at 6adc5a3: Map settings saved
- Pull request #960 at c8e2a28: Fix draw state name in scripts
Copy file name to clipboardExpand all lines: Source/Orts.Simulation/Simulation/RollingStocks/MSTSSteamLocomotive.cs
+38-7Lines changed: 38 additions & 7 deletions
Original file line number
Diff line number
Diff line change
@@ -122,6 +122,9 @@ public class MSTSSteamLocomotive : MSTSLocomotive
122
122
bool WaterMotionPump1IsOn = false;
123
123
bool WaterMotionPump2IsOn = false;
124
124
float WaterMotionPumpHeatLossBTU;
125
+
bool WaterMotionPumpLockedOut = false;
126
+
float WaterMotionPumpLockOutResetTimeS = 15.0f; // Time to reset the pump lock out time - time to prevent change of pumps
127
+
float WaterMotionPumpLockOutTimeS; // Current lock out time - reset after Reset Time exceeded
125
128
public bool CylinderCocksAreOpen;
126
129
public bool BlowdownValveOpen;
127
130
public bool CylinderCompoundOn; // Flag to indicate whether compound locomotive is in compound or simple mode of operation - simple = true (ie bypass valve is open)
@@ -1155,8 +1158,9 @@ public override void Save(BinaryWriter outf)
1155
1158
outf.Write(Injector2IsOn);
1156
1159
outf.Write(Injector2Fraction);
1157
1160
outf.Write(InjectorLockedOut);
1161
+
outf.Write(WaterMotionPumpLockedOut);
1158
1162
outf.Write(InjectorLockOutTimeS);
1159
-
outf.Write(InjectorLockOutResetTimeS);
1163
+
outf.Write(WaterMotionPumpLockOutTimeS);
1160
1164
outf.Write(WaterTempNewK);
1161
1165
outf.Write(BkW_Diff);
1162
1166
outf.Write(WaterFraction);
@@ -1219,8 +1223,9 @@ public override void Restore(BinaryReader inf)
// calculate Water steam heat based on injector water delivery temp
7043
-
BoilerMassLB += elapsedClockSeconds * TotalPumpFlowRateLbpS; // Boiler Mass increase by Injector both pumps
7044
-
BoilerHeatBTU -= elapsedClockSeconds * WaterMotionPumpHeatLossBTU; // Total loss of boiler heat due to water injection - inject steam and water Heat
7056
+
BoilerMassLB += elapsedClockSeconds * TotalPumpFlowRateLbpS; // Boiler Mass increase by both pumps
7057
+
BoilerHeatBTU -= elapsedClockSeconds * WaterMotionPumpHeatLossBTU; // Total loss of boiler heat due to water pump - inject cold water straight from tender
7045
7058
// InjectorBoilerInputLB += (elapsedClockSeconds * Injector1Fraction * InjectorFlowRateLBpS); // Keep track of water flow into boilers from Injector 1
7046
7059
BoilerHeatOutBTUpS += WaterMotionPumpHeatLossBTU; // Total loss of boiler heat due to water injection - inject steam and water Heat
if (WaterGlassLevelIN > 7.99) // turn pumps off if water level in boiler greater then 8.0, to stop cycling
7246
7275
{
7247
7276
WaterMotionPump1IsOn = false;
7248
7277
WaterMotionPump2IsOn = false;
7249
7278
}
7250
-
else if (WaterGlassLevelIN <= 7.0 && WaterGlassLevelIN > 5.75) // turn water pump #1 on if water level in boiler drops below 7.0 and is above
7279
+
else if (WaterGlassLevelIN <= 7.0 && WaterGlassLevelIN > 5.75 && !WaterMotionPumpLockedOut) // turn water pump #1 on if water level in boiler drops below 7.0 and is above
7251
7280
{
7252
7281
WaterMotionPump1IsOn = true;
7253
7282
WaterMotionPump2IsOn = false;
7283
+
WaterMotionPumpLockedOut = true;
7254
7284
}
7255
-
else if (WaterGlassLevelIN <= 5.75 && WaterGlassLevelIN > 4.5) // turn water pump #1 on if water level in boiler drops below 7.0 and is above
7285
+
else if (WaterGlassLevelIN <= 5.75 && WaterGlassLevelIN > 4.5 && !WaterMotionPumpLockedOut) // turn water pump #2 on as well if water level in boiler drops below 5.75 and is above
0 commit comments