public void LoadCache(ResourceLocation location, string path)
{
if (_loadedCaches.ContainsKey(location))
throw new InvalidOperationException("A resource cache for the " + location + " location has already been loaded.");
var file = new FileInfo(path);
using (var stream = file.OpenRead())
{
_loadedCaches[location] = new LoadedCache
{
Cache = new ResourceCache(stream),
File = file
};
}
}