26 lines
654 B
C#
26 lines
654 B
C#
using Convention;
|
|
using Demo.Game.Attr;
|
|
using Dreamteck.Splines;
|
|
using System;
|
|
using System.Collections;
|
|
using UnityEngine;
|
|
|
|
namespace Demo.Game
|
|
{
|
|
[Scriptable]
|
|
public class SplineTrackRenderer : BasicSplineRenderer<PathGenerator>
|
|
{
|
|
public static SplineTrackRenderer Make()
|
|
{
|
|
return new GameObject().AddComponent<SplineTrackRenderer>();
|
|
}
|
|
|
|
protected override IEnumerator DoSomethingDuringApplyScript()
|
|
{
|
|
if (MyDefaultMaterial == null)
|
|
MyDefaultMaterial = StaticCacheDefaultMaterial;
|
|
yield return base.DoSomethingDuringApplyScript();
|
|
}
|
|
}
|
|
}
|