summaryrefslogtreecommitdiff
path: root/src/engine.cpp
diff options
context:
space:
mode:
authorBjörn Steinbrink <B.Steinbrink@gmx.de>2006-02-23 16:02:00 +0000
committerBjörn Steinbrink <B.Steinbrink@gmx.de>2006-02-23 16:02:00 +0000
commit05a12d5568111fa13759026442ed358605bf9a28 (patch)
tree9948a2351c846dee1b36f25a90d1429aa78dda23 /src/engine.cpp
parent3737fb9fd3ff6072f83bdc514f88ad0fdbf4da6c (diff)
downloadmana-client-05a12d5568111fa13759026442ed358605bf9a28.tar.gz
mana-client-05a12d5568111fa13759026442ed358605bf9a28.tar.bz2
mana-client-05a12d5568111fa13759026442ed358605bf9a28.tar.xz
mana-client-05a12d5568111fa13759026442ed358605bf9a28.zip
A bunch of mostly cosmetic cleanups.
Diffstat (limited to 'src/engine.cpp')
-rw-r--r--src/engine.cpp9
1 files changed, 7 insertions, 2 deletions
diff --git a/src/engine.cpp b/src/engine.cpp
index 4a637777..879a6b21 100644
--- a/src/engine.cpp
+++ b/src/engine.cpp
@@ -136,7 +136,12 @@ void Engine::changeMap(std::string mapPath)
std::string oldMusic = "";
// Notify the minimap and beingManager about the map change
- minimap->setMap(newMap);
+ Image *mapImage = NULL;
+ if (newMap->hasProperty("minimap")) {
+ ResourceManager *resman = ResourceManager::getInstance();
+ mapImage = resman->getImage(newMap->getProperty("minimap"));
+ }
+ minimap->setMapImage(mapImage);
beingManager->setMap(newMap);
if (mCurrentMap) {
@@ -252,7 +257,7 @@ void Engine::draw(Graphics *graphics)
// Draw player nickname, speech, and emotion sprite as needed
Beings *beings = beingManager->getAll();
- for (Beings::iterator i = beings->begin(); i != beings->end(); i++)
+ for (BeingIterator i = beings->begin(); i != beings->end(); i++)
{
(*i)->drawSpeech(graphics, -map_x, -map_y);
(*i)->drawName(graphics, -map_x, -map_y);