|
@@ -18,25 +18,25 @@
|
|
|
void FioFCloseFile(FILE *f);
|
|
|
FILE *FioFOpenFile(const std::string &filename, const char *mode, Subdirectory subdir, size_t *filesize = nullptr);
|
|
|
bool FioCheckFileExists(const std::string &filename, Subdirectory subdir);
|
|
|
std::string FioFindFullPath(Subdirectory subdir, const char *filename);
|
|
|
std::string FioGetDirectory(Searchpath sp, Subdirectory subdir);
|
|
|
std::string FioFindDirectory(Subdirectory subdir);
|
|
|
void FioCreateDirectory(const std::string &name);
|
|
|
|
|
|
const char *FiosGetScreenshotDir();
|
|
|
|
|
|
void SanitizeFilename(char *filename);
|
|
|
void AppendPathSeparator(std::string &buf);
|
|
|
void DeterminePaths(const char *exe);
|
|
|
void DeterminePaths(const char *exe, bool only_local_path);
|
|
|
std::unique_ptr<char[]> ReadFileToMem(const std::string &filename, size_t &lenp, size_t maxsize);
|
|
|
bool FileExists(const std::string &filename);
|
|
|
bool ExtractTar(const std::string &tar_filename, Subdirectory subdir);
|
|
|
|
|
|
extern std::string _personal_dir; ///< custom directory for personal settings, saves, newgrf, etc.
|
|
|
extern std::vector<Searchpath> _valid_searchpaths;
|
|
|
|
|
|
/** Helper for scanning for files with a given name */
|
|
|
class FileScanner {
|
|
|
protected:
|
|
|
Subdirectory subdir; ///< The current sub directory we are searching through
|
|
|
public:
|