Skip to content

Commit 5e43f5c

Browse files
committed
Fix: Loco brake delay issue
1 parent 259016f commit 5e43f5c

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

source/OpenBVE/Parsers/Train/TrainDatParser.cs

+8
Original file line numberDiff line numberDiff line change
@@ -299,12 +299,20 @@ internal static void ParseTrainData(string FileName, System.Text.Encoding Encodi
299299
{
300300
Train.Handles.LocoBrake.DelayUp = Lines[i].Split(',').Select(Convert.ToDouble).ToArray();
301301
}
302+
else
303+
{
304+
Train.Handles.LocoBrake.DelayUp = new[] {a};
305+
}
302306
break;
303307
case 5:
304308
if (currentFormat == TrainDatFormats.openBVE && myVersion >= 1534)
305309
{
306310
Train.Handles.LocoBrake.DelayDown = Lines[i].Split(',').Select(Convert.ToDouble).ToArray();
307311
}
312+
else
313+
{
314+
Train.Handles.LocoBrake.DelayDown = new[] {a};
315+
}
308316
break;
309317
}
310318
} i++; n++;

0 commit comments

Comments
 (0)