启动页放12张图每次启动随机显示其中的一张的代码
12张图片命名合理一点,NSInteger minute = [[[NSCalendar currentCalendar] components:NSMinuteCalendarUnit fromDate:[NSDate date]] minute];
splashView = [[UIImageView alloc] initWithFrame:self.window.frame];
splashView.autoresizingMask = (UIViewAutoresizingFlexibleWidth|UIViewAutoresizingFlexibleHeight);
splashView.image = [UIImage imageNamed:[NSString stringWithFormat:@"splash%d.png", minute % SPLASH_IMG_COUNT]];
图片命名有规律:12张图片比如说,image1.png,image2.png,^