Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Raúl Uranga helped to finally upload this small utility to Github and here comes his repo fork!
Objective-C C C++
branch: master

This branch is even with rauluranga:master

Fetching latest commit…

Cannot retrieve the latest commit at this time

Failed to load latest commit information.
ResourceLoaderTest.xcodeproj
ResourceLoaderTest
.gitattributes
.gitignore
README.markdown

README.markdown

Works with the latest version of Cocos2D.

Usage

// load resources
ResourcesLoader *loader = [ResourcesLoader sharedLoader];
NSArray *extensions = [NSArray arrayWithObjects:@"png", @"wav", nil];

for (NSString *extension in extensions) {
    NSArray *paths = [[NSBundle mainBundle] pathsForResourcesOfType:extension inDirectory:nil];
    for (NSString *filename in paths) {
        filename = [[filename componentsSeparatedByString:@"/"] lastObject];
        [loader addResources:filename, nil];
    }
}

// load it async
[loader loadResources:self];
Something went wrong with that request. Please try again.