偷看Hierarchy

试图做一点优化但是失败了(
在下面控制台输loopg("track名字",int)可以在某个track下生成一大堆pathnode来测试Hierarchy的性能
目前超过5000就卡了
This commit is contained in:
2025-02-10 15:56:10 +08:00
parent d3928be99f
commit 30653e133b
8 changed files with 426 additions and 371 deletions

View File

@@ -2,6 +2,7 @@ using System.Collections;
using System.Collections.Generic;
using Ichni.RhythmGame;
using UnityEngine;
using UnityEngine.UI;
namespace Ichni.Editor
{
@@ -9,14 +10,17 @@ namespace Ichni.Editor
{
public GameObject hierarchyTabPrefab;
public RectTransform tabContainer;
public List<HierarchyTab> tabList;
public void GenerateTab(GameElement targetElement, GameElement parentElement)
{
HierarchyTab tab = Instantiate(hierarchyTabPrefab, tabContainer).GetComponent<HierarchyTab>();
tab.SetTab(targetElement, parentElement);
tabList.Add(tab);
}
}
}