加载性能优化, 暂时放弃异步加载

This commit is contained in:
2025-12-11 18:03:57 +08:00
parent eebf283e12
commit b99b7f2743
9 changed files with 150 additions and 138 deletions

View File

@@ -1,4 +1,5 @@
using System.Collections;
using Convention;
using Dreamteck.Splines;
using UnityEngine;
@@ -10,7 +11,9 @@ namespace Demo.Game
public static SplineNode Make()
{
return new GameObject("", typeof(Node)).AddComponent<SplineNode>();
var node = new GameObject("", typeof(Node)).AddComponent<SplineNode>();
node.m_MyNode = node.GetOrAddComponent<Node>();
return node;
}
private Node m_MyNode;
@@ -21,15 +24,7 @@ namespace Demo.Game
public int MyNodeContent = 0;
public Node MyNode
{
get
{
if (m_MyNode == null)
m_MyNode = GetComponent<Node>();
return m_MyNode;
}
}
public Node MyNode => m_MyNode;
public void AddTo(SplineCore core)
{