22 return std::format(
"addons/voltmod/plugins/{}",
plugin);
std::filesystem::path ResolvePath(std::string_view relativePath)
a relative path against the base directory. If the path is already absolute, returns it as-is.
void SetBaseDir(const std::filesystem::path &baseDir)
Set the base directory for path resolution (the host's csgo directory). Must be called during initial...
static std::string ReadFile(const std::filesystem::path &path)
std::string PluginFile(std::string_view plugin, std::string_view relative)
"addons/voltmod/plugins/<plugin>/<relative>".
static std::filesystem::path g_baseDir
std::string PluginDir(std::string_view plugin)
"addons/voltmod/plugins/<plugin>". Pure string building, so safe at static init.