Proper constructor for resources