System.NullReferenceException at Orts.Simulation.Physics.Train.GetTrainInfoAuto (when passing a red signal)

Bug #1819381 reported by Brady McClelland
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Open Rails
Expired
Undecided
Unassigned

Bug Description

Hello folks,

I created an activity on the ConnRiver route and I have found that the program crashes to desktop if I pass a red signal. I have been able to replicate the bug during two different activities on the route; both times instead of going into emergency brake mode, the game just crashes. In the current activity, I am operating a static train from a yard and theres a signal that won't let me get permission to pass. I suspect that an AI train thats further up the line heading toward me is not letting me clear the signal. So, I tried to force my way past since the AI train is few towns down the line and has several signals in between us, but the program seems to terminate the moment that the emergency brake should engage when passing the red signal.

The error pop-up I get is:
Error: System.NullReferenceException: Object reference not set to an instance of an object.
   at Orts.Simulation.Physics.Train.GetTrainInfoAuto(TrainInfo& thisInfo) in E:\Documents\Coding\Jenkins\jobs\Open Rails Stable\workspace\Source\Orts.Simulation\Simulation\Physics\Train.cs:line 13127
   at Orts.Simulation.Physics.Train.GetTrainInfo() in E:\Documents\Coding\Jenkins\jobs\Open Rails Stable\workspace\Source\Orts.Simulation\Simulation\Physics\Train.cs:line 13073
   at Orts.Viewer3D.Popups.TrackMonitorWindow.PrepareFrame(ElapsedTime elapsedTime, Boolean updateFull) in E:\Documents\Coding\Jenkins\jobs\Open Rails Stable\workspace\Source\RunActivity\Viewer3D\Popups\TrackMonitorWindow.cs:line 126
   at Orts.Viewer3D.Popups.Window.PrepareFrame(RenderFrame frame, ElapsedTime elapsedTime, Boolean updateFull) in E:\Documents\Coding\Jenkins\jobs\Open Rails Stable\workspace\Source\RunActivity\Viewer3D\Popups\Window.cs:line 227
   at Orts.Viewer3D.Popups.WindowManager.PrepareFrame(RenderFrame frame, ElapsedTime elapsedTime) in E:\Documents\Coding\Jenkins\jobs\Open Rails Stable\workspace\Source\RunActivity\Viewer3D\Popups\WindowManager.cs:line 209
   at Orts.Viewer3D.Viewer.Update(RenderFrame frame, Single elapsedRealTime) in E:\Documents\Coding\Jenkins\jobs\Open Rails Stable\workspace\Source\RunActivity\Viewer3D\Viewer.cs:line 798
   at Orts.Viewer3D.Processes.GameStateViewer3D.Update(RenderFrame frame, Double totalRealSeconds) in E:\Documents\Coding\Jenkins\jobs\Open Rails Stable\workspace\Source\RunActivity\Viewer3D\Processes\GameStateViewer3D.cs:line 121
   at Orts.Viewer3D.Processes.UpdaterProcess.Update() in E:\Documents\Coding\Jenkins\jobs\Open Rails Stable\workspace\Source\RunActivity\Viewer3D\Processes\UpdaterProcess.cs:line 128
   at Orts.Viewer3D.Processes.UpdaterProcess.DoUpdate() in E:\Documents\Coding\Jenkins\jobs\Open Rails Stable\workspace\Source\RunActivity\Viewer3D\Processes\UpdaterProcess.cs:line 108
   at Orts.Viewer3D.Processes.UpdaterProcess.UpdaterThread() in E:\Documents\Coding\Jenkins\jobs\Open Rails Stable\workspace\Source\RunActivity\Viewer3D\Processes\UpdaterProcess.cs:line 74
   at System.Threading.ThreadHelper.ThreadStart_Context(Object state)
   at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state)
   at System.Threading.ThreadHelper.ThreadStart()

Tags: crash physics
Revision history for this message
Brady McClelland (bmcclelland) wrote :
summary: - Program crashes when passes a red signal
+ Program crashes when passing a red signal
description: updated
Revision history for this message
Carlo Santucci (carlosanit1) wrote : Re: Program crashes when passing a red signal

What do you mean by "I am operating a static train"? Have you switched player train to a static consist?
Can you attach a screenshot (showing track monitor, train list window and also the dispatcher info HUD) taken just before passing the red signal?

Changed in or:
status: New → Incomplete
James Ross (twpol)
summary: - Program crashes when passing a red signal
+ System.NullReferenceException at
+ Orts.Simulation.Physics.Train.GetTrainInfoAuto when passing a red signal
summary: System.NullReferenceException at
- Orts.Simulation.Physics.Train.GetTrainInfoAuto when passing a red signal
+ Orts.Simulation.Physics.Train.GetTrainInfoAuto (when passing a red
+ signal)
tags: added: physics
Revision history for this message
Launchpad Janitor (janitor) wrote :

[Expired for Open Rails because there has been no activity for 60 days.]

Changed in or:
status: Incomplete → Expired
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.