mirror of
https://github.com/Outer-Wilds-New-Horizons/new-horizons.git
synced 2025-12-11 20:15:44 +01:00
Revert "test both remove children methods"
This reverts commit 0fa7cfe2c528bbf9cb3bd598395c04d4dd3df39f.
This commit is contained in:
parent
165f94d1cd
commit
c5ae20d22b
@ -1,4 +1,3 @@
|
||||
using HarmonyLib;
|
||||
using NewHorizons.Builder.General;
|
||||
using NewHorizons.Components;
|
||||
using NewHorizons.Components.Orbital;
|
||||
@ -229,16 +228,12 @@ namespace NewHorizons.Builder.Props
|
||||
var path = $"{detailPath}/{childPath}";
|
||||
|
||||
var flag = true;
|
||||
var childObjs = transforms.Where(x => x.GetPath() == path).ToList();
|
||||
var childObjs2 = go.transform.FindAll(childPath);
|
||||
foreach (var childObj in childObjs)
|
||||
foreach (var childObj in transforms.Where(x => x.GetPath() == path))
|
||||
{
|
||||
flag = false;
|
||||
childObj.gameObject.SetActive(false);
|
||||
}
|
||||
|
||||
Main.Instance.ModHelper.Console.WriteLine($"remove children detail\n{prop.transform.GetPath()}\n{childPath}\n\n{childObjs.Join()}\n{childObjs2.Join()}");
|
||||
|
||||
if (flag) NHLogger.LogWarning($"Couldn't find \"{childPath}\".");
|
||||
}
|
||||
}
|
||||
|
||||
@ -1,4 +1,3 @@
|
||||
using HarmonyLib;
|
||||
using NewHorizons.Builder.Atmosphere;
|
||||
using NewHorizons.Builder.Body;
|
||||
using NewHorizons.Builder.General;
|
||||
@ -1009,9 +1008,7 @@ namespace NewHorizons.Handlers
|
||||
var path = $"{goPath}/{childPath}";
|
||||
|
||||
var flag = true;
|
||||
var childObjs = transforms.Where(x => x.GetPath() == path).ToList();
|
||||
var childObjs2 = go.transform.FindAll(childPath);
|
||||
foreach (var childObj in childObjs)
|
||||
foreach (var childObj in transforms.Where(x => x.GetPath() == path))
|
||||
{
|
||||
flag = false;
|
||||
// idk why we wait here but we do
|
||||
@ -1024,8 +1021,6 @@ namespace NewHorizons.Handlers
|
||||
}, 2);
|
||||
}
|
||||
|
||||
Main.Instance.ModHelper.Console.WriteLine($"remove children planet\n{go.transform.GetPath()}\n{childPath}\n\n{childObjs.Join()}\n{childObjs2.Join()}");
|
||||
|
||||
if (flag) NHLogger.LogWarning($"Couldn't find \"{childPath}\".");
|
||||
}
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user