Синтаксис:
Используется csharp
ParticleSystem ps = GetComponentInChildren<ParticleSystem>();
ArrayList p0 = new ArrayList();
for( int k=0; k<10; k++ )
{
ParticleSystem.Patricle p = new ParticleSystem.Particle();
p.position = new Vector3((float)k,0,(float)k);
p.startLifeTime = 99999f;
p.size = 20f;
p0.Add(p);
}
ps.SetParticles(p0.ToArray(typeof(UnityEngine.ParticleSystem.Particle)) as UnityEngine.ParticleSystem.Particle[],p0.Count);
ps.Play();
ArrayList p0 = new ArrayList();
for( int k=0; k<10; k++ )
{
ParticleSystem.Patricle p = new ParticleSystem.Particle();
p.position = new Vector3((float)k,0,(float)k);
p.startLifeTime = 99999f;
p.size = 20f;
p0.Add(p);
}
ps.SetParticles(p0.ToArray(typeof(UnityEngine.ParticleSystem.Particle)) as UnityEngine.ParticleSystem.Particle[],p0.Count);
ps.Play();