/// <summary> /// 设置粒子生成器 /// </summary> /// <param name="generator"></param> public virtual void SetParticleGenerator(IParticleGenerator generator) { _generator = generator; if (_generator != null) { _emitter.AttachGenerator(_generator); } }
/// <summary> /// 设置粒子发射器 /// </summary> /// <param name="emitter"></param> public virtual void SetParticleEmitter(IParticleEmitter emitter) { _emitter = emitter; if (_generator != null) { _emitter.AttachGenerator(_generator); } }