HTML5   发布时间:2022-04-27  发布网站:大佬教程  code.js-code.com
大佬教程收集整理的这篇文章主要介绍了CAEmitterCell大佬教程大佬觉得挺不错的,现在分享给大家,也给大家做个参考。
-( void )awakeFromNib
{
  CAEmitterLayer* fireEmitter = (CAEmitterLayer*) self .layer; ;
     fireEmitter.emitterPosition = CGPointMake ( .bounds.size.width/ 2 , .bounds.size.height);
fireEmitter.emitterMode =   kCAEmitterLayerOutline;
fireEmitter.emitterShape = kCAEmitterLayerLine;
 
fireEmitter.emitterSize = CGSizeMake 5 );
 
     float gas= .7 ;
     // Create the fire emitter cell
CAEmitterCell *fire = [CAEmitterCell emitterCell];
fire.emissionLongitude = @H_986_80@m_PI ;
fire.emissionLatitude = - / ;
fire.birthRate = 0 ; //100*gas;
fire.lifetime=gas;
fire.lifetimeRange=gas* 0 .35 ;
fire.VeLocity = 80 ;
fire.VeLocityRange = 21 ;
fire.EmissionRange = 1 .1 f;
fire.yAcceleration = - 200 ;
fire.ScaleSpeed = .3 f;
fire.color=[[ UIColor colorWithRed: .8 green: .4 blue: .2 alpha: ] CGColor ];
fire.contents = ( id )[[ UIImage imagenamed: @"fire.png" CGImage ];
[fire setName: @"fire" ];
 
CAEmitterCell *smoke = [CAEmitterCell emitterCell];
smoke.birthRate = //11;
smoke.emissionLongitude = - ;
smoke.emissionLatitude=- ;
smoke.lifetime = gas* 4 ;
smoke.VeLocity = 40 ;
smoke.VeLocityRange = 20 ;
smoke.emissionRange = / ;
smoke.Spin = 1 ;
smoke.SpinRange = 6 ;
smoke.yAcceleration = - 160 ;
smoke.Scale = f;
smoke.AlphaSpeed = - .22 f;
smoke.ScaleSpeed = f;
smoke.color=[[ *gas] ];
 
smoke.contents = ( @"smoke.png" ];
[smoke setName: @"smoke" ];
 
fireEmitter.emitterCells = [ NSArray arrayWithObjects:smoke,fire,157)!important">nil ];
}

you can download Hanukkah Menorah on the app store Now for FREE. It supports both the iPad and iPhone. It also has some in-app-Purchases to change from the default menorah.

大佬总结

以上是大佬教程为你收集整理的CAEmitterCell全部内容,希望文章能够帮你解决CAEmitterCell所遇到的程序开发问题。

如果觉得大佬教程网站内容还不错,欢迎将大佬教程推荐给程序员好友。

本图文内容来源于网友网络收集整理提供,作为学习参考使用,版权属于原作者。
如您有任何意见或建议可联系处理。小编QQ:384754419,请注明来意。
标签:caemittercell