loading resources from file