修改粒子追踪器

Signed-off-by: TRADER_FOER <lhf190@outlook.com>
This commit is contained in:
2026-07-29 22:23:06 +08:00
parent 923fc5359f
commit 58afd6acc1
2 changed files with 12 additions and 3 deletions

View File

@@ -26,6 +26,7 @@ namespace Ichni.RhythmGame
public float lifeTime;
public bool isAutoOrient;
public Vector3 particleRotation;
public ParticleController.PathNodeSizeMode pathNodeSizeMode;
#endregion
#region [] Calculated & Cached States
@@ -45,7 +46,8 @@ namespace Ichni.RhythmGame
bool prewarm, float playTime, float stopTime,
bool is3D, float width, Vector3 extendDirection,
float density, float lifeTime,
bool isAutoOrient, Vector3 particleRotation)
bool isAutoOrient, Vector3 particleRotation,
ParticleController.PathNodeSizeMode pathNodeSizeMode = ParticleController.PathNodeSizeMode.LegacyOffset)
{
ParticleTracker particleTracker = Instantiate(GameManager.Instance.basePrefabs.particleTracker, track.transform)
.GetComponent<ParticleTracker>();
@@ -57,6 +59,7 @@ namespace Ichni.RhythmGame
particleTracker.stopTime = stopTime;
particleTracker.themeBundleName = themeBundleName;
particleTracker.materialName = materialName;
particleTracker.pathNodeSizeMode = pathNodeSizeMode;
(particleTracker as IHaveParticles).SetParticleMaterial(themeBundleName, materialName);
particleTracker.SetParticleSettings(prewarm, is3D, width, extendDirection, density, lifeTime, isAutoOrient, particleRotation);
return particleTracker;
@@ -137,6 +140,7 @@ namespace Ichni.RhythmGame
particleController.is3D = is3D;
particleController.width = width;
particleController.extendDirection = extendDirection;
particleController.pathNodeSizeMode = pathNodeSizeMode;
particleController.Rebuild();
}