不会说话的汤姆猫
NSString *format=dict[@"imageFormat"]; NSInteger frames=[dict[@"frames"] integerValue]; NSMutableArray * imageList=[NSMutableArray array]; for (NSInteger i=0; i<frames; i++) { NSString *fileName=[NSString stringWithFormat:format,i]; UIImage* image=[UIImage imageNamed:fileName]; [imageList addObject:image]; } [_tomcatImageView setAnimationImages:imageList]; [_tomcatImageView setAnimationDuration:frames/10.0]; [_tomcatImageView setAnimationRepeatCount:1]; [_tomcatImageView startAnimating]; // NSArray *soundFiles=dict[@"soundFiles"]; if (soundFiles.count>0) { NSInteger seed=arc4random() %soundFiles.count; [self loadSoundWithFileName:soundFiles[seed]]; } }
- 1
- 2
- 3
- 4
- 5
- 6
- 13
- 粉丝: 56
- 资源: 3
- 我的内容管理 展开
- 我的资源 快来上传第一个资源
- 我的收益 登录查看自己的收益
- 我的积分 登录查看自己的积分
- 我的C币 登录后查看C币余额
- 我的收藏
- 我的下载
- 下载帮助