Skip to content

Commit 55ab04e

Browse files
authored
Make syncCompressor operator precedence more obvious
1 parent 64f4876 commit 55ab04e

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Source/Orts.Simulation/Simulation/RollingStocks/MSTSLocomotive.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2708,7 +2708,7 @@ protected virtual void UpdateCompressor(float elapsedClockSeconds)
27082708
foreach (TrainCar locoCar in locoGroup)
27092709
{
27102710
if (locoCar is MSTSLocomotive loco)
2711-
syncCompressor |= (locoGroup.Contains(this as TrainCar) || CompressorIsMUControlled && loco.CompressorIsMUControlled)
2711+
syncCompressor |= (locoGroup.Contains(this as TrainCar) || (CompressorIsMUControlled && loco.CompressorIsMUControlled))
27122712
&& loco.CompressorIsOn && loco.MainResPressurePSI < loco.MaxMainResPressurePSI;
27132713

27142714
// No need to check repeatedly if we already know to sync compressors

0 commit comments

Comments
 (0)