1
0
mirror of https://github.com/originalnicodr/CinematicUnityExplorer.git synced 2026-10-10 04:53:15 +08:00

Fixed the new Hud toggle to work with CPP releases and deleted unnecessary namespace usage.

This commit is contained in:
originalnicodr
2024-02-04 11:05:01 -03:00
parent b294880409
commit 406502f485
+6 -3
View File
@@ -1,5 +1,4 @@
using UnityEngine;
using UnityExplorer.CacheObject;
using UnityExplorer.CacheObject;
using UnityExplorer.Inspectors;
using UnityExplorer.ObjectExplorer;
using UniverseLib.UI;
@@ -67,7 +66,11 @@ namespace UnityExplorer.UI.Panels
}
}
else {
disabledCanvases = GameObject.FindObjectsOfType<Canvas>().Where(c => c.isActiveAndEnabled).ToList();
disabledCanvases = RuntimeHelper.FindObjectsOfTypeAll(typeof(Canvas))
.Select(obj => obj.TryCast<Canvas>())
.Where(c => !c.name.Contains("unityexplorer") && c.isActiveAndEnabled)
.ToList();
foreach (Canvas canvas in disabledCanvases)
{
if (canvas == null)