1
0
mirror of https://github.com/zenorogue/hyperrogue.git synced 2024-11-17 10:44:48 +00:00

added file_exists function

This commit is contained in:
Zeno Rogue 2021-03-31 12:14:23 +02:00
parent 4aff89134e
commit b622a7ac42

View File

@ -699,4 +699,8 @@ EX string decompress_string(string s) {
}
#endif
EX bool file_exists(string fname) {
return access(fname.c_str(), F_OK) != -1;
}
}