diff options
-rw-r--r-- | src/gui/minimap.cpp | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/src/gui/minimap.cpp b/src/gui/minimap.cpp index f155faaea..e86fac09a 100644 --- a/src/gui/minimap.cpp +++ b/src/gui/minimap.cpp @@ -152,7 +152,7 @@ void Minimap::setMap(const Map *const map) else { std::string tempname = paths.getStringValue("minimaps") - + "graphics/minimaps/" + map->getFilename() + ".png"; + + map->getFilename() + ".png"; ResourceManager *const resman = ResourceManager::getInstance(); minimapName = map->getProperty("minimap"); @@ -160,6 +160,13 @@ void Minimap::setMap(const Map *const map) if (minimapName.empty() && resman->exists(tempname)) minimapName = tempname; + if (minimapName.empty()) + { + tempname = "graphics/minimaps/" + map->getFilename() + ".png"; + if (resman->exists(tempname)) + minimapName = tempname; + } + mMapImage = resman->getImage(minimapName); mCustomMapImage = false; } |