Permalink
Browse files

Made 'data' subdir also searched in the working dir. This helps debug…

…ging from an IDE. You may want to remove it, but that's comfortable to me!
  • Loading branch information...
1 parent 841f165 commit 8d4fd7530844efbe3245766593360ac615a04ae7 @Sukender Sukender committed Mar 31, 2012
Showing with 5 additions and 0 deletions.
  1. +5 −0 src/FileSystem.cpp
View
@@ -10,6 +10,7 @@ namespace FileSystem {
static FileSourceFS dataFilesApp(GetDataDir());
static FileSourceFS dataFilesUser(GetUserDir("data"));
+ static FileSourceFS dataFilesWorkingDir("data");
FileSourceUnion gameDataFiles;
FileSourceFS rawFileSystem("/");
@@ -100,6 +101,10 @@ namespace FileSystem {
{
gameDataFiles.AppendSource(&dataFilesUser);
gameDataFiles.AppendSource(&dataFilesApp);
+
+ // "Working dir" added by Sukender. This helps debugging from an IDE by simply setting the working dir as needed.
+ // If you feel this is too much, you may remove it.
+ gameDataFiles.AppendSource(&dataFilesWorkingDir);
}
void Uninit()

0 comments on commit 8d4fd75

Please sign in to comment.