源码介绍:可爱的汤姆猫会实现吃早餐、打哈欠等搞笑动作。源码效果:源码片段:-(void)btnClick:(UIButton*)button{if(button.tag==1){NSMutableArray*arrM=[[NSMutableArrayalloc]init];for(NSIntegeri=0;i<12;i++){NSString*name=[NSStringstringWithFormat:@"cat_cymbal00%02ld.jpg",i];[arrMaddObject:[UIImageimageNamed:name]];}imageView.animationImages=arrM;imageView.animationDuration=3.0;imageView.animationRepeatCount=1;[imageViewstartAnimating];[selfperformSelector:@selector(playSoundWithFileName:)withObject:@"cymbal"afterDelay:0.5];}elseif(button.tag==2){NSMutableArray*arrM=[[NSMutableArrayalloc]init];for(NSIntegeri=0;i<27;i++){NSString*name=[NSStringstringWithFormat:@"cat_fart00%02ld.jpg",i];[arrMaddObject:[UIImageimageNamed:name]];}imageView.animationImages=arrM;imageView.animationDuration=5.0;imageView.animationRepeatCount=1;[imageViewstartAnimating];[selfperformSelector:@selector(playSoundWithFileName:)withObject:@"fart003_11025"afterDelay:0.6];}elseif(button.tag==3){NSMutableArray*arrM=[[NSMutableArrayalloc]init];for(NSIntegeri=0;i<39;i++){NSString*name=[NSStringstringWithFormat:@"cat_eat00%02ld.jpg",i];[arrMaddObject:[UIImageimageNamed:name]];}imageView.animationImages=arrM;imageView.animationDuration=3.0;imageView.animationRepeatCount=1;[imageViewstartAnimating];[selfperformSelector:@selector(playSoundWithFileName:)withObject:@”p_eat"afterDelay:0.5];}下载地址:http://down.51cto.com/data/2111751
