diff options
Diffstat (limited to 'src/crepe/api/Config.h')
-rw-r--r-- | src/crepe/api/Config.h | 23 |
1 files changed, 18 insertions, 5 deletions
diff --git a/src/crepe/api/Config.h b/src/crepe/api/Config.h index 88220a7..56e3af5 100644 --- a/src/crepe/api/Config.h +++ b/src/crepe/api/Config.h @@ -7,16 +7,17 @@ namespace crepe { class Config { private: Config() = default; - public: ~Config() = default; public: //! Retrieve handle to global Config instance - static Config & get_instance() { - static Config instance; - return instance; - } + static Config & get_instance(); + // singleton + Config(const Config &) = delete; + Config(Config &&) = delete; + Config & operator = (const Config &) = delete; + Config & operator = (Config &&) = delete; public: //! Logging-related settings @@ -36,6 +37,17 @@ public: bool color = true; } log; + //! Save manager + struct { + /** + * \brief Save file location + * + * This location is used by the constructor of SaveManager, and should be + * set before save manager functionality is attempted to be used. + */ + std::string location = "save.crepe.db"; + } savemgr; + //! physics-related settings struct { /** @@ -48,3 +60,4 @@ public: }; } // namespace crepe + |