summaryrefslogtreecommitdiff
path: root/src/resourcemanager.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/resourcemanager.cpp')
-rw-r--r--src/resourcemanager.cpp8
1 files changed, 7 insertions, 1 deletions
diff --git a/src/resourcemanager.cpp b/src/resourcemanager.cpp
index d45e96e4..f40fc232 100644
--- a/src/resourcemanager.cpp
+++ b/src/resourcemanager.cpp
@@ -139,11 +139,17 @@ ResourceManager::searchAndAddZipFiles()
#endif
}
+bool ResourceManager::exists(std::string const &path)
+{
+ return PHYSFS_exists(path.c_str());
+}
+
void*
ResourceManager::loadFile(const std::string &fileName, int &fileSize)
{
// If the file doesn't exist indicate failure
- if (!PHYSFS_exists(fileName.c_str())) {
+ if (!exists(fileName))
+ {
LOG_WARN("Warning: " << fileName << " not found!");
return NULL;
}