summaryrefslogtreecommitdiff
path: root/src/resources
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2012-11-09 16:21:59 +0300
committerAndrei Karas <akaras@inbox.ru>2012-11-09 16:21:59 +0300
commita360f4e0af9df1d5276f977d68ac2f357b14ffae (patch)
treeec13f49e5a4ee16dbdb5fbd69ce53d3c60969a06 /src/resources
parent2541754f6c607acfd1304af38280b534f7a8e0d7 (diff)
downloadmv-a360f4e0af9df1d5276f977d68ac2f357b14ffae.tar.gz
mv-a360f4e0af9df1d5276f977d68ac2f357b14ffae.tar.bz2
mv-a360f4e0af9df1d5276f977d68ac2f357b14ffae.tar.xz
mv-a360f4e0af9df1d5276f977d68ac2f357b14ffae.zip
Fix code style.
Diffstat (limited to 'src/resources')
-rw-r--r--src/resources/mapreader.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/resources/mapreader.cpp b/src/resources/mapreader.cpp
index 51d762569..15ac55853 100644
--- a/src/resources/mapreader.cpp
+++ b/src/resources/mapreader.cpp
@@ -254,7 +254,6 @@ Map *MapReader::readMap(XmlNodePtr node, const std::string &path)
// Take the filename off the path
const std::string pathDir = path.substr(0, path.rfind("/") + 1);
- const std::string fileName = path.substr(path.rfind("/") + 1);
const int w = XML::getProperty(node, "width", 0);
const int h = XML::getProperty(node, "height", 0);
@@ -278,6 +277,7 @@ Map *MapReader::readMap(XmlNodePtr node, const std::string &path)
#ifdef USE_OPENGL
if (graphicsManager.getUseAtlases())
{
+ const std::string fileName = path.substr(path.rfind("/") + 1);
const MapDB::MapInfo *const info = MapDB::getMapAtlas(fileName);
if (info)
{