aboutsummaryrefslogtreecommitdiff
path: root/src/Config.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/Config.cpp')
-rw-r--r--src/Config.cpp25
1 files changed, 16 insertions, 9 deletions
diff --git a/src/Config.cpp b/src/Config.cpp
index f558ef6..5745f34 100644
--- a/src/Config.cpp
+++ b/src/Config.cpp
@@ -28,19 +28,25 @@ namespace Config
const char* kConfigFile = "melonDS.ini";
-int _3DRenderer;
-int Threaded3D;
+char BIOS9Path[1024];
+char BIOS7Path[1024];
+char FirmwarePath[1024];
-int GL_ScaleFactor;
-int GL_Antialias;
+char DSiBIOS9Path[1024];
+char DSiBIOS7Path[1024];
+char DSiFirmwarePath[1024];
+char DSiNANDPath[1024];
ConfigEntry ConfigFile[] =
{
- {"3DRenderer", 0, &_3DRenderer, 1, NULL, 0},
- {"Threaded3D", 0, &Threaded3D, 1, NULL, 0},
+ {"BIOS9Path", 1, BIOS9Path, 0, "", 1023},
+ {"BIOS7Path", 1, BIOS7Path, 0, "", 1023},
+ {"FirmwarePath", 1, FirmwarePath, 0, "", 1023},
- {"GL_ScaleFactor", 0, &GL_ScaleFactor, 1, NULL, 0},
- {"GL_Antialias", 0, &GL_Antialias, 0, NULL, 0},
+ {"DSiBIOS9Path", 1, DSiBIOS9Path, 0, "", 1023},
+ {"DSiBIOS7Path", 1, DSiBIOS7Path, 0, "", 1023},
+ {"DSiFirmwarePath", 1, DSiFirmwarePath, 0, "", 1023},
+ {"DSiNANDPath", 1, DSiNANDPath, 0, "", 1023},
{"", -1, NULL, 0, NULL, 0}
};
@@ -82,7 +88,8 @@ void Load()
while (!feof(f))
{
fgets(linebuf, 1024, f);
- int ret = sscanf(linebuf, "%32[A-Za-z_0-9]=%[^\t\n]", entryname, entryval);
+ int ret = sscanf(linebuf, "%31[A-Za-z_0-9]=%[^\t\n]", entryname, entryval);
+ entryname[31] = '\0';
if (ret < 2) continue;
ConfigEntry* entry = &ConfigFile[0];