mirror of
https://github.com/BeamMP/BeamMP-Server.git
synced 2026-04-03 14:26:09 +00:00
Add GetFilename, GetExtension,
This commit is contained in:
@@ -311,3 +311,11 @@ std::pair<bool, std::string> LuaAPI::FS::Copy(const std::string& Path, const std
|
||||
bool LuaAPI::FS::Exists(const std::string& Path) {
|
||||
return fs::exists(fs::relative(Path));
|
||||
}
|
||||
|
||||
std::string LuaAPI::FS::GetFilename(const std::string& Path) {
|
||||
return fs::path(Path).filename().string();
|
||||
}
|
||||
|
||||
std::string LuaAPI::FS::GetExtension(const std::string& Path) {
|
||||
return fs::path(Path).extension().string();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user