diff options
author | Bjørn Lindeijer <bjorn@lindeijer.nl> | 2007-01-04 02:20:38 +0000 |
---|---|---|
committer | Bjørn Lindeijer <bjorn@lindeijer.nl> | 2007-01-04 02:20:38 +0000 |
commit | 4eec29ac0f6a9b05562ac0fbe3d4e5d7e82deeac (patch) | |
tree | 0b18ed6970f8fdd6750459e6f9032e444d253580 /src/engine.cpp | |
parent | e160ba567bf3d2ae915e67c12c13e213c1a32a62 (diff) | |
download | mana-client-4eec29ac0f6a9b05562ac0fbe3d4e5d7e82deeac.tar.gz mana-client-4eec29ac0f6a9b05562ac0fbe3d4e5d7e82deeac.tar.bz2 mana-client-4eec29ac0f6a9b05562ac0fbe3d4e5d7e82deeac.tar.xz mana-client-4eec29ac0f6a9b05562ac0fbe3d4e5d7e82deeac.zip |
Merged 0.0 changes from revision 2898 to 2988 to trunk.
Diffstat (limited to 'src/engine.cpp')
-rw-r--r-- | src/engine.cpp | 32 |
1 files changed, 2 insertions, 30 deletions
diff --git a/src/engine.cpp b/src/engine.cpp index 30f0097e..d2ce6d6f 100644 --- a/src/engine.cpp +++ b/src/engine.cpp @@ -54,42 +54,19 @@ extern Minimap *minimap; char itemCurrenyQ[10] = "0"; Spriteset *emotionset; -Spriteset *npcset; -std::vector<Spriteset *> weaponset; Engine::Engine(): mCurrentMap(NULL) { - // Load the sprite sets + // Load the emotion set ResourceManager *resman = ResourceManager::getInstance(); - - npcset = resman->getSpriteset("graphics/sprites/npcs.png", 50, 80); - emotionset = resman->getSpriteset("graphics/sprites/emotions.png", - 30, 32); - for (int i = 0; i < 2; i++) - { - Spriteset *tmp = ResourceManager::getInstance()->getSpriteset( - "graphics/sprites/weapon" + toString(i) + ".png", 64, 64); - if (!tmp) { - logger->error("Unable to load weaponset"); - } else { - weaponset.push_back(tmp); - } - } - - if (!npcset) logger->error("Unable to load NPC spriteset!"); + emotionset = resman->getSpriteset("graphics/sprites/emotions.png", 30, 32); if (!emotionset) logger->error("Unable to load emotions spriteset!"); } Engine::~Engine() { - // Delete sprite sets - npcset->decRef(); emotionset->decRef(); - - std::for_each(weaponset.begin(), weaponset.end(), - std::mem_fun(&Spriteset::decRef)); - weaponset.clear(); } void Engine::changeMap(const std::string &mapPath) @@ -142,8 +119,3 @@ void Engine::logic() beingManager->logic(); gui->logic(); } - -void Engine::draw(Graphics *graphics) -{ - gui->draw(); -} |