mirror of
https://github.com/glest/glest-source.git
synced 2025-01-17 21:28:21 +01:00
No more issues I think
This commit is contained in:
parent
3d3c3f909f
commit
73cc3dcf4e
@ -217,9 +217,7 @@ namespace Game {
|
||||
|
||||
#if defined(DATADIR)
|
||||
if (foundPath == false) {
|
||||
foundPath =
|
||||
tryCustomPath(cfgType, fileName,
|
||||
formatPath(TOSTRING(DATADIR)));
|
||||
foundPath = tryCustomPath(cfgType, fileName, endPathWithSlash(formatPath(TOSTRING(DATADIR))));
|
||||
}
|
||||
#endif
|
||||
|
||||
|
@ -5737,12 +5737,6 @@ namespace Game {
|
||||
}
|
||||
PlatformExceptionHandler::disableBacktrace = disableBacktrace;
|
||||
|
||||
#if defined(DATADIR)
|
||||
if (SystemFlags::VERBOSE_MODE_ENABLED)
|
||||
printf("\n\nDATADIR = [%s]\n\n",
|
||||
formatPath(TOSTRING(DATADIR)).c_str());
|
||||
#endif
|
||||
|
||||
const int
|
||||
knownArgCount = sizeof(GAME_ARGS) / sizeof(GAME_ARGS[0]);
|
||||
for (int idx = 1; idx < argc; ++idx) {
|
||||
|
@ -225,16 +225,15 @@ namespace Shared {
|
||||
SDL_SetRelativeMouseMode(SDL_FALSE);
|
||||
SDL_SetRelativeMouseMode(SDL_TRUE);
|
||||
}
|
||||
|
||||
|
||||
#ifndef WIN32
|
||||
string icon_file = "";
|
||||
#if defined(DATADIR)
|
||||
if (fileExists(formatPath(TOSTRING(DATADIR)) + "glest.png")) {
|
||||
icon_file = formatPath(TOSTRING(DATADIR)) + "glest.png";
|
||||
} else if (fileExists(formatPath(TOSTRING(DATADIR)) + "glest.bmp")) {
|
||||
icon_file = formatPath(TOSTRING(DATADIR)) + "glest.bmp";
|
||||
if (fileExists(endPathWithSlash(formatPath(TOSTRING(DATADIR))) + "glest.png")) {
|
||||
icon_file = endPathWithSlash(formatPath(TOSTRING(DATADIR))) + "glest.png";
|
||||
} else if (fileExists(endPathWithSlash(formatPath(TOSTRING(DATADIR))) + "glest.bmp")) {
|
||||
icon_file = endPathWithSlash(formatPath(TOSTRING(DATADIR))) + "glest.bmp";
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
if (icon_file == "" && fileExists("glest.png")) {
|
||||
|
@ -262,18 +262,10 @@ namespace Shared {
|
||||
mapTagReplacementValues["%%APPLICATIONPATH%%"] = Properties::applicationPath;
|
||||
mapTagReplacementValues["{APPLICATIONPATH}"] = Properties::applicationPath;
|
||||
|
||||
/*#if defined(DATADIR)
|
||||
mapTagReplacementValues["$APPLICATIONDATAPATH"] = formatPath(TOSTRING(DATADIR));
|
||||
mapTagReplacementValues["%%APPLICATIONDATAPATH%%"] = formatPath(TOSTRING(DATADIR));
|
||||
mapTagReplacementValues["{APPLICATIONDATAPATH}"] = formatPath(TOSTRING(DATADIR));
|
||||
|
||||
#else*/
|
||||
mapTagReplacementValues["$APPLICATIONDATAPATH"] = Properties::applicationDataPath;
|
||||
mapTagReplacementValues["%%APPLICATIONDATAPATH%%"] = Properties::applicationDataPath;
|
||||
mapTagReplacementValues["{APPLICATIONDATAPATH}"] = Properties::applicationDataPath;
|
||||
|
||||
//#endif
|
||||
|
||||
mapTagReplacementValues["{TECHTREEPATH}"] = Properties::techtreePath;
|
||||
mapTagReplacementValues["{SCENARIOPATH}"] = Properties::scenarioPath;
|
||||
mapTagReplacementValues["{TUTORIALPATH}"] = Properties::tutorialPath;
|
||||
@ -395,18 +387,10 @@ namespace Shared {
|
||||
replaceAll(value, "%%APPLICATIONPATH%%", Properties::applicationPath);
|
||||
replaceAll(value, "{APPLICATIONPATH}", Properties::applicationPath);
|
||||
|
||||
/*#if defined(DATADIR)
|
||||
replaceAll(value, "$APPLICATIONDATAPATH", formatPath(TOSTRING(DATADIR)));
|
||||
replaceAll(value, "%%APPLICATIONDATAPATH%%", formatPath(TOSTRING(DATADIR)));
|
||||
replaceAll(value, "{APPLICATIONDATAPATH}", formatPath(TOSTRING(DATADIR)));
|
||||
|
||||
#else*/
|
||||
replaceAll(value, "$APPLICATIONDATAPATH", Properties::applicationDataPath);
|
||||
replaceAll(value, "%%APPLICATIONDATAPATH%%", Properties::applicationDataPath);
|
||||
replaceAll(value, "{APPLICATIONDATAPATH}", Properties::applicationDataPath);
|
||||
|
||||
//#endif
|
||||
|
||||
replaceAll(value, "{TECHTREEPATH}", Properties::techtreePath);
|
||||
// if(value.find("{SCENARIOPATH}") != string::npos) {
|
||||
// printf("\n\n** WILL REPLACE [%s]\n",value.c_str());
|
||||
|
Loading…
x
Reference in New Issue
Block a user