Skip to content

Commit

Permalink
Fix #428: NRE in UpdateAllVesselData in sandbox mode
Browse files Browse the repository at this point in the history
  • Loading branch information
JonnyOThan committed Feb 24, 2025
1 parent 2cf335e commit cb76a95
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 0 deletions.
3 changes: 3 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,9 @@
- Fixed usages of .material in favor of .sharedMaterial (thanks @Gameslinx)
- Fixed some incorrect .cfg syntax (thanks @HebaruSan)
- Improved Russian localization (thanks @Sooll3)
- Fixed missing vessel icons and visual map mode in RPM MFDs (thanks @vulkans22)
- Fixed NRE when loading a sandbox game
- Fixed NRE when loading a vessel with a running narrow band scanner


## 20.4 - 2020-9-9
Expand Down
5 changes: 5 additions & 0 deletions SCANsat/SCANutil.cs
Original file line number Diff line number Diff line change
Expand Up @@ -1080,6 +1080,11 @@ internal static CelestialBody getTargetBody(MapObject target)

internal static void UpdateAllVesselData(Vessel v)
{
if (ResearchAndDevelopment.Instance == null)
{
return;
}

List<ScienceData> data = new List<ScienceData>();

var science = v.FindPartModulesImplementing<IScienceDataContainer>();
Expand Down

0 comments on commit cb76a95

Please sign in to comment.