]> git.jsancho.org Git - lugaru.git/blobdiff - Source/Utils/Folders.hpp
Save progress upon level completion
[lugaru.git] / Source / Utils / Folders.hpp
index 52be0f0d8b59d0b81042a6ef44308bfd3eb4e936..9d52c49291958df83401ed7ccd1496a9aab9af40 100644 (file)
@@ -47,9 +47,6 @@ public:
     /* Returns path to the screenshot directory. Creates it if needed. */
     static std::string getScreenshotDir();
 
-    /* Returns full path for a game resource */
-    static std::string getResourcePath(std::string filepath);
-
     /* Returns full path for user data */
     static std::string getUserDataPath();
 
@@ -58,6 +55,12 @@ public:
 
     static FILE* openMandatoryFile(std::string filename, const char* mode);
 
+    /* Returns full path for a game resource */
+    static inline std::string getResourcePath(std::string filepath) { return dataDir + '/' + filepath; }
+
+    /* Returns full path for user progress save */
+    static inline std::string getUserSavePath() { return getUserDataPath() + "/users"; }
+
 private:
     static const char* getHomeDirectory();
     static std::string getGenericDirectory(const char* ENVVAR, const std::string fallback);