private void OnEnable() { if (targets.Length == 1) { FastSoftParticle _target = (FastSoftParticle)target; ParticleSystemRenderer particleSystemRenderer = _target.GetComponent <ParticleSystemRenderer>(); if (particleSystemRenderer.AreVertexStreamsEnabled(ParticleSystemVertexStreams.Custom1) == false) { Undo.RecordObject(_target, "EnableVertexStreams,ParticleSystemVertexStreams.Custom1"); particleSystemRenderer.EnableVertexStreams(ParticleSystemVertexStreams.Custom1); } } }