2025-09-25 19:04:05 +08:00
|
|
|
using Convention;
|
2025-12-12 15:19:10 +08:00
|
|
|
using Demo.Attr;
|
2025-09-25 19:04:05 +08:00
|
|
|
using Dreamteck.Splines;
|
2025-12-12 15:19:10 +08:00
|
|
|
using System;
|
|
|
|
|
using System.Collections;
|
2025-09-25 19:04:05 +08:00
|
|
|
using UnityEngine;
|
|
|
|
|
|
|
|
|
|
namespace Demo.Game
|
|
|
|
|
{
|
2025-12-12 15:19:10 +08:00
|
|
|
[Scriptable]
|
2025-10-07 01:45:52 +08:00
|
|
|
public class SplineTrackRenderer : BasicSplineRenderer<PathGenerator>
|
2025-09-25 19:04:05 +08:00
|
|
|
{
|
|
|
|
|
public static SplineTrackRenderer Make()
|
|
|
|
|
{
|
|
|
|
|
return new GameObject().AddComponent<SplineTrackRenderer>();
|
|
|
|
|
}
|
|
|
|
|
|
2025-11-25 10:52:39 +08:00
|
|
|
protected override IEnumerator DoSomethingDuringApplyScript()
|
2025-10-04 23:09:46 +08:00
|
|
|
{
|
2025-11-25 10:52:39 +08:00
|
|
|
if (MyDefaultMaterial == null)
|
|
|
|
|
MyDefaultMaterial = StaticCacheDefaultMaterial;
|
|
|
|
|
yield return base.DoSomethingDuringApplyScript();
|
2025-10-04 23:09:46 +08:00
|
|
|
}
|
2025-09-25 19:04:05 +08:00
|
|
|
}
|
|
|
|
|
}
|