added datadir_t resource loading