mirror of
https://github.com/glest/glest-source.git
synced 2025-10-03 10:51:55 +02:00
Added the ability to tell mega-glest where to look for glest.ini, servers.ini and all of the various .log files. The new optional environment variable that mega-glest will look for is:
GLESTHOME
This commit is contained in:
@@ -25,6 +25,14 @@ Configuration::~Configuration(){
|
||||
}
|
||||
|
||||
void Configuration::load(const string &path){
|
||||
|
||||
if(fileExists(path) == false) {
|
||||
throw runtime_error("Cannot find file: " + path);
|
||||
}
|
||||
else if(fileExists(fileName) == false) {
|
||||
throw runtime_error("Cannot find file: " + fileName);
|
||||
}
|
||||
|
||||
loadStructure(path);
|
||||
loadValues(fileName);
|
||||
}
|
||||
|
Reference in New Issue
Block a user