DarkflameServer/dCommon/BinaryPathFinder.h
Jonathan Romano f8f5b731f1
Allow servers to be run from directories other than build. Read/write files relative to binary instead of cwd (#834)
Allows the server to be run from a non-build directory.  Also only read or write files relative to the build directory, regardless of where the server is run from
2022-11-27 03:59:59 -08:00

16 lines
270 B
C++

#pragma once
#ifndef __BINARYPATHFINDER__H__
#define __BINARYPATHFINDER__H__
#include <filesystem>
class BinaryPathFinder {
private:
static std::filesystem::path binaryDir;
public:
static std::filesystem::path GetBinaryDir();
};
#endif //!__BINARYPATHFINDER__H__