MPMoviePlayerController problem when play a movie
- by Momeks
hi .. i put a movie when my application will lunch . just like gameloft games .
so when application has lunched , movie plays fine but before the move plays .. my FirstViewController xib file show first then moview start to play ! why ?
here is my code :
- (void)applicationDidFinishLaunching:(UIApplication *)application {
NSBundle *bundle = [NSBundle mainBundle];
NSString *moviePath = [bundle pathForResource:@"movie" ofType:@"m4v"];
NSURL *movieURL = [[NSURL fileURLWithPath:moviePath] retain];
MPMoviePlayerController *IntroMovie = [[MPMoviePlayerController alloc] initWithContentURL:movieURL];
IntroMovie.movieControlMode = MPMovieControlModeHidden;
[IntroMovie play];
}