Skip to content

Commit 54d1119

Browse files
committed
Bug fix for https://bugs.launchpad.net/or/+bug/2047300 Dynamic tracks disappear after long tunnel
1 parent 362e836 commit 54d1119

File tree

2 files changed

+13
-0
lines changed

2 files changed

+13
-0
lines changed

Source/RunActivity/Viewer3D/DynamicTrack.cs

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -707,6 +707,17 @@ public static PitchControls GetPitchControl(string sPitchControl)
707707

708708
}
709709
}
710+
711+
/// <summary>
712+
/// Marks the generic track profile, so that its textures never get deleted
713+
/// </summary>
714+
[CallOnThread("Loader")]
715+
public void Mark()
716+
{
717+
foreach (LOD lod in LODs)
718+
lod.Mark();
719+
}
720+
710721
}
711722

712723
public class LOD

Source/RunActivity/Viewer3D/World.cs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -116,6 +116,8 @@ public void Load()
116116
Precipitation.Mark();
117117
Terrain.Mark();
118118
Scenery.Mark();
119+
Viewer.TRP?.TrackProfile?.Mark();
120+
Viewer.TRP?.TrackProfileTun?.Mark();
119121
Trains.Mark();
120122
RoadCars.Mark();
121123
Containers.Mark();

0 commit comments

Comments
 (0)