This all started when I changed my_sound.mp3 to another sound with the same name in ‘Supporting Files’ folder, but after compiling app was still playing the old one. After that I’ve done a lot of manipulations.
What I’ve tried:
-
Delete app from iPhone and from Simulator
-
Delete all from Library/Developer/Xcode/DerivedData
-
Product > Clean in Xcode
Now my app don’t see my_sound.mp3 at all…
How I check:
NSString* path = [[NSBundle mainBundle] pathForResource:@"my_sound" ofType:@"mp3"];
if (![[NSFileManager defaultManager] fileExistsAtPath:path]) {
NSLog(@"No file");
}
Files created long time ago in ‘Supporting Files’ are available.
“Is my_sound.mp3 listed with the correct name in the “Copy Bundle Resources” section of the target’s Build Phases?” – Phillip Mills Aug 4 at 19:00