diff options
author | Bjørn Lindeijer <bjorn@lindeijer.nl> | 2009-04-29 23:24:39 +0200 |
---|---|---|
committer | Bjørn Lindeijer <bjorn@lindeijer.nl> | 2009-04-29 23:24:39 +0200 |
commit | f016894763970ad5601d1fb2de10431fb876ff53 (patch) | |
tree | ae2ccf42ec3880dc6de6c0f206b4bc4cd095f0a9 /src/engine.cpp | |
parent | 5fd5b71ad0be6d1ac5665ec4d5f0aafff25646fd (diff) | |
download | mana-f016894763970ad5601d1fb2de10431fb876ff53.tar.gz mana-f016894763970ad5601d1fb2de10431fb876ff53.tar.bz2 mana-f016894763970ad5601d1fb2de10431fb876ff53.tar.xz mana-f016894763970ad5601d1fb2de10431fb876ff53.zip |
Some random cleanups
Diffstat (limited to 'src/engine.cpp')
-rw-r--r-- | src/engine.cpp | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/src/engine.cpp b/src/engine.cpp index ece98d5d..1bd6c30f 100644 --- a/src/engine.cpp +++ b/src/engine.cpp @@ -96,16 +96,14 @@ bool Engine::changeMap(const std::string &mapPath) std::string oldMusic = ""; if (mCurrentMap) - { oldMusic = mCurrentMap->getProperty("music"); - delete mCurrentMap; - } std::string newMusic = newMap->getProperty("music"); if (newMusic != oldMusic) sound.playMusic(newMusic); + delete mCurrentMap; mCurrentMap = newMap; Net::getMapHandler()->mapLoaded(mapPath); |