调整谱面开放

This commit is contained in:
SoulliesOfficial
2026-04-01 01:35:17 -04:00
parent 25b6da25ae
commit e9393c64f7
29 changed files with 466 additions and 2802 deletions

View File

@@ -60,7 +60,7 @@ namespace Ichni.RhythmGame.ThemeBundles.DepartureToMultiverse
dtmTrail.headSize = headSize;
dtmTrail.widthCurve = widthCurve ?? DefaultWidthCurve();
dtmTrail.trailAlphaGradient = trailGradient ?? DefaultTrailGradient();
return dtmTrail;
}
@@ -75,13 +75,15 @@ namespace Ichni.RhythmGame.ThemeBundles.DepartureToMultiverse
public override void FirstSetUpObject(bool isFirstGenerated)
{
trailRenderer = trailBody.GetComponent<TrailRenderer>();
trailRenderer.emitting = false;
if (visibleTimeLength.animations.Count == 0) trailRenderer.time = 5f;
// 初始化默认值(兼容旧存档中未序列化字段)
if (widthCurve == null || widthCurve.keys.Length == 0) widthCurve = DefaultWidthCurve();
if (trailAlphaGradient == null) trailAlphaGradient = DefaultTrailGradient();
trailRenderer.widthCurve = widthCurve;
// 收集所有使用 BlendUnlit 的 Renderer
renderers.Clear();
CollectBlendUnlitRenderer(headPoint);
@@ -229,10 +231,10 @@ namespace Ichni.RhythmGame.ThemeBundles.DepartureToMultiverse
DisableHead();
isHeadEnabled = false;
}
visibleTimeLength.UpdateFlexibleFloat(songTime);
if (visibleTimeLength.animations.Count > 0 && trailRenderer.time != visibleTimeLength.value)
if (visibleTimeLength.animations.Count > 0)
{
visibleTimeLength.UpdateFlexibleFloat(songTime);
trailRenderer.time = visibleTimeLength.value;
}