Skip to content

Commit 95ca8e9

Browse files
committed
Automatic merge of T1.5.1-1692-g8b2dd97c0 and 15 pull requests
- Pull request #900 at 4629736: DMI in 3D cab + two more dials - Pull request #1030 at d3ae4a2: Refactor settings, in prep for settings exporter - Pull request #1045 at cc4d53c: Bugfix: Empty Start Time for Explore, and other issues loading from Menu Selection and Content Routes - Pull request #1052 at 5bbc476: Content Manager: Add axle count, and lowest derail force - Pull request #1062 at 3b18c48: Train Forces popup Window. - Pull request #1064 at 9b3415e: Add Train Info tab to Help window (F1) - Pull request #1066 at 62c89c1: Log derailment, using TraceInformation. - Pull request #892 at 1f5ba4c: Signal Function OPP_SIG_ID_TRAINPATH - Pull request #1000 at d8d9709: Locomotive operation from control car - Pull request #1029 at 92c74ef: Superelevation Follow Up Fixes - Pull request #1057 at 50c3789: Switchable brake system - Pull request #1065 at 409064d: Fix for PantographToggle sound event - Pull request #1069 at ffd1af4: Mouse wheel control only with Alt – Followup for #1051 - Pull request #1055 at 90bbcff: Route Based TTrack Sounds - Pull request #896 at f1681df: First implementation of https://blueprints.launchpad.net/or/+spec/specific-sounds-for-ai-trains
17 parents 2bc8fb1 + 8b2dd97 + 4629736 + d3ae4a2 + cc4d53c + 5bbc476 + 3b18c48 + 9b3415e + 62c89c1 + 1f5ba4c + d8d9709 + 92c74ef + 50c3789 + 409064d + ffd1af4 + 90bbcff + f1681df commit 95ca8e9

File tree

4 files changed

+81
-5
lines changed

4 files changed

+81
-5
lines changed

Source/Documentation/Manual/physics.rst

Lines changed: 70 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2678,6 +2678,46 @@ For EP brakes, two variants are available:
26782678
actuating the cylinders. This system is sometimes called "UIC EP brake". It is typically the system
26792679
used in high speed trains.
26802680

2681+
Defining Multiple Brake Systems
2682+
-------------------------------
2683+
2684+
It is possible to define multiple systems within ``OrtsBrakeMode`` sections::
2685+
2686+
ORTSBrakeMode (
2687+
ORTSBrakeModeName ( AG )
2688+
BrakeSystemType( Air_single_pipe )
2689+
Comment ( All brake parameters are available in such a section )
2690+
)
2691+
ORTSBrakeMode (
2692+
ORTSBrakeModeName ( VB )
2693+
BrakeSystemType( Vacuum_single_pipe )
2694+
Comment ( All brake parameters are available in such a section )
2695+
)
2696+
2697+
These sections can be used to either define dual vacuum/air rolling stock, or
2698+
can be used to define the brake modes of the UIC stock in the following form::
2699+
2700+
BrakeSystemType( Air_twin_pipe )
2701+
ORTSBrakeMode (
2702+
ORTSBrakeModeName ( G )
2703+
ORTSBrakeMass ( 67t )
2704+
Comment ( All brake parameters are available in such a section )
2705+
)
2706+
ORTSBrakeMode (
2707+
ORTSBrakeModeName ( P )
2708+
ORTSBrakeMass ( 83t )
2709+
BrakeSystemType( Vacuum_single_pipe )
2710+
Comment ( All brake parameters are available in such a section )
2711+
)
2712+
2713+
Available brake mode names to be used are: GG, G, PP, P, RR, R, R_MG, AG, AP, AU, VB, VP, VU.
2714+
With the ``ORTSBrakeModeNames`` keyword the used brake modes can be filtered,
2715+
for being able to define them in an include file, and using only the needed
2716+
ones. It can be used e.g. in the following form::
2717+
2718+
ORTSBrakeModeNames ( "P, R" )
2719+
2720+
26812721
.. _physics-brake-controller:
26822722

26832723
Train Brake Controller Positions
@@ -3087,6 +3127,13 @@ using the ORTSBrakeShoeFriction parameter, 1D (ie, speed only, see above section
30873127

30883128
``ORTSNumberCarBrakeShoes`` - to facilitate the operation of the default 2D curves above it is necessary to configure the number of brake shoes for each car.
30893129

3130+
``ORTSBrakeMass`` - Railways part of the UIC organisation instead of NBR
3131+
provide brake masses, measured in tonnes, which is a virtual value to define
3132+
the brake efficiency. Openrails uses this value as an alternative to setting
3133+
the max brake shoe force directly, and recalculates this to that force using
3134+
approximating formulas to the published UIC brake curves. This parameter is
3135+
ignored if the ``ORTSMaxBrakeShoeForce`` also set.
3136+
30903137
Whilst OR will attempt to set some defaults if parameters are left out, the most realistic operation will be achieved by using all the relevant parameters.
30913138

30923139
The following two legacy arrangements can be used as an alternative to the above method,
@@ -3095,6 +3142,26 @@ The following two legacy arrangements can be used as an alternative to the above
30953142

30963143
- Legacy #2 - where MaxBrakeForce and ORTSBrakeShoeFriction have been set, legacy operation will remain unchanged.
30973144

3145+
Load Compensation
3146+
-----------------
3147+
3148+
Load compensation stages can be defined in the following way::
3149+
3150+
OrtsLoadStage (
3151+
OrtsBrakeMass ( 28t )
3152+
Comment ( All brake parameters are available in such a section )
3153+
)
3154+
OrtsLoadStage (
3155+
OrtsBrakeMass ( 37t )
3156+
OrtsLoadStageMinMass ( 34t )
3157+
Comment ( All brake parameters are available in such a section )
3158+
)
3159+
3160+
The ``OrtsLoadStageMinMass`` parameter defines the minimum car mass (together
3161+
with the load) where the stage can be activated without risking the brake lock.
3162+
For the lowest stage this keyword should be omitted. In OpenRails the switching
3163+
between stages is automatic.
3164+
30983165

30993166
Train Brake Pipe Losses
31003167
-----------------------
@@ -3597,10 +3664,11 @@ The retainers of a car will only be available if either the General Option
35973664
:ref:`Retainer valve on all cars <options-retainers>` is checked, or the car's
35983665
.wag file contains a retainer valve declaration. To declare a retainer the line
35993666
``BrakeEquipmentType ( )`` in the .wag file must include either the item
3600-
``Retainer_4_Position`` or the item ``Retainer_3_Position``. A 4 position
3667+
``Retainer_4_Position``, ``Retainer_3_Position`` or ``UIC_mountain``. A 4 position
36013668
retainer includes four states: exhaust, low pressure (10 psi), high pressure
36023669
(20 psi), and slow direct (gradual drop to zero). A 3 position retainer does
3603-
not include the low pressure position. The use and display of the retainers is
3670+
not include the low pressure position. The UIC plain-mountain switch has only
3671+
2 positions. The use and display of the retainers is
36043672
described in :ref:`Extended HUD for Brake Information <physics-hud-brake>`.
36053673

36063674
The setting of the retained pressure and the number of retainers is

Source/Orts.Simulation/Simulation/RollingStocks/MSTSWagon.cs

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1383,6 +1383,7 @@ public virtual void Parse(string lowercasetoken, STFReader stf)
13831383
case "wagon(ortsbrakemode":
13841384
var newSystem = BrakeSystem.CreateNewLike(BrakeSystem, this)?.InitializeDefault(); // Start with the same BrakeSystemType() as the base
13851385
BrakeModes? brakeModeName = null;
1386+
List<string> brakeEquipment = null;
13861387

13871388
stf.VerifyStartOfBlock();
13881389
while (!stf.EndOfBlock())
@@ -1419,6 +1420,12 @@ public virtual void Parse(string lowercasetoken, STFReader stf)
14191420
else
14201421
BrakeSystems.Add(key, newSystem);
14211422
}
1423+
if (brakeEquipment != null)
1424+
(newSystem as MSTSBrakeSystem)?.SetBrakeEquipment(brakeEquipment);
1425+
break;
1426+
case "wagon(ortsbrakemode(brakeequipmenttype":
1427+
brakeEquipment = stf.ReadStringBlock("").ToLower().Replace(" ", "").Split(',').ToList();
1428+
(newSystem as MSTSBrakeSystem)?.SetBrakeEquipment(brakeEquipment);
14221429
break;
14231430
case "wagon(ortsbrakemode(ortsloadstage":
14241431
var stage = BrakeSystem.CreateNewLike(newSystem, this).InitializeDefault();

Source/Orts.Simulation/Simulation/RollingStocks/SubSystems/Brakes/MSTS/AirSinglePipe.cs

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -402,7 +402,7 @@ public override string[] GetDebugStatus(Dictionary<BrakeSystemComponent, Pressur
402402
TwoPipes ? FormatStrings.FormatPressure(BrakeLine2PressurePSI, PressureUnit.PSI, units[BrakeSystemComponent.MainPipe], true) : string.Empty,
403403
BrakeValve == BrakeValveType.Distributor ? FormatStrings.FormatPressure(ControlResPressurePSI, PressureUnit.PSI, units[BrakeSystemComponent.AuxiliaryReservoir], true) : string.Empty,
404404
SupplyReservoirPresent ? FormatStrings.FormatPressure(SupplyResPressurePSI, PressureUnit.PSI, units[BrakeSystemComponent.SupplyReservoir], true) : string.Empty,
405-
RetainerPositions == 0 ? string.Empty : RetainerDebugState,
405+
RetainerPositions <= 0 ? string.Empty : RetainerDebugState,
406406
Simulator.Catalog.GetString(GetStringAttribute.GetPrettyName(TripleValveState)),
407407
string.Empty, // Spacer because the state above needs 2 columns.
408408
HandBrakePresent ? string.Format("{0:F0}%", HandbrakePercent) : string.Empty,
@@ -482,7 +482,7 @@ public override void SetBrakeEquipment(List<string> equipment)
482482
if (equipment.Contains("retainer_4_position")) RetainerPositions = 4;
483483
else if (equipment.Contains("retainer_3_position")) RetainerPositions = 3;
484484
else if (equipment.Contains("uic_mountain")) RetainerPositions = 2;
485-
else RetainerPositions = 0;
485+
else RetainerPositions = -1;
486486
SupplyReservoirPresent = equipment.Contains("supply_reservoir");
487487
EmergencySolenoidValve = equipment.Contains("emergency_solenoid_valve");
488488
}
@@ -2515,6 +2515,7 @@ public override void SetRetainer(RetainerSetting setting)
25152515
{
25162516
switch (RetainerPositions)
25172517
{
2518+
case -1:
25182519
case 0:
25192520
case 1: setting = RetainerSetting.Exhaust; break;
25202521
case 2: if (setting == RetainerSetting.LowPressure || setting == RetainerSetting.HighPressure) setting = RetainerSetting.SlowDirect; break;

Source/Orts.Simulation/Simulation/RollingStocks/SubSystems/Brakes/MSTS/SMEBrakeSystem.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -86,7 +86,7 @@ public override string[] GetDebugStatus(Dictionary<BrakeSystemComponent, Pressur
8686
EmergencyReservoirPresent ? FormatStrings.FormatPressure(EmergResPressurePSI, PressureUnit.PSI, units[BrakeSystemComponent.EmergencyReservoir], true) : string.Empty,
8787
TwoPipes ? FormatStrings.FormatPressure(CylPressurePSI, PressureUnit.PSI, units[BrakeSystemComponent.MainPipe], true) : string.Empty,
8888
BrakeValve == BrakeValveType.Distributor ? FormatStrings.FormatPressure(ControlResPressurePSI, PressureUnit.PSI, units[BrakeSystemComponent.AuxiliaryReservoir], true) : string.Empty,
89-
RetainerPositions == 0 ? string.Empty : RetainerDebugState,
89+
RetainerPositions <= 0 ? string.Empty : RetainerDebugState,
9090
Simulator.Catalog.GetString(GetStringAttribute.GetPrettyName(TripleValveState)),
9191
string.Empty, // Spacer because the state above needs 2 columns.
9292
string.Empty,

0 commit comments

Comments
 (0)