mirror of
https://github.com/Outer-Wilds-New-Horizons/new-horizons.git
synced 2025-12-11 20:15:44 +01:00
fuck it we ball
This commit is contained in:
parent
a6b3911e93
commit
b5fafc59c8
@ -92,6 +92,9 @@ namespace NewHorizons.Utility
|
|||||||
{
|
{
|
||||||
if (CachedGameObjects.TryGetValue(path, out var go)) return go;
|
if (CachedGameObjects.TryGetValue(path, out var go)) return go;
|
||||||
|
|
||||||
|
go = GameObject.Find(path);
|
||||||
|
if (go != null) return go;
|
||||||
|
|
||||||
var names = path.Split('/');
|
var names = path.Split('/');
|
||||||
var rootName = names[0];
|
var rootName = names[0];
|
||||||
var root = SceneManager.GetActiveScene().GetRootGameObjects().FirstOrDefault(x => x.name == rootName);
|
var root = SceneManager.GetActiveScene().GetRootGameObjects().FirstOrDefault(x => x.name == rootName);
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user