From d2009f7637f2938e6a1ded724c00921ac1d08f73 Mon Sep 17 00:00:00 2001 From: JohnCorby Date: Sun, 22 May 2022 13:07:22 -0700 Subject: [PATCH] add all da sun station debris instead of just the first one --- NewHorizons/Utility/AstroObjectLocator.cs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/NewHorizons/Utility/AstroObjectLocator.cs b/NewHorizons/Utility/AstroObjectLocator.cs index c4c9779f..8d33aa59 100644 --- a/NewHorizons/Utility/AstroObjectLocator.cs +++ b/NewHorizons/Utility/AstroObjectLocator.cs @@ -131,7 +131,8 @@ namespace NewHorizons.Utility case AstroObject.Name.CustomString: if (primary._customName.Equals("Sun Station")) { - otherChildren.Add(GameObject.Find("SS_Debris_Body")); + // there are multiple debris with the same name + otherChildren.AddRange(GameObject.FindObjectsOfType().Where(x => x.name == "SS_Debris_Body")); } break; default: