Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changeset 9869 in orxonox.OLD for trunk/src/story_entities/menu/game_menu.cc


Ignore:
Timestamp:
Oct 3, 2006, 12:19:30 AM (18 years ago)
Author:
bensch
Message:

orxonox/trunk: merged the new_class_id branche back to the trunk.
merged with command:
svn merge https://svn.orxonox.net/orxonox/branches/new_class_id trunk -r9683:HEAD
no conflicts… puh..

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/story_entities/menu/game_menu.cc

    r9656 r9869  
    2222
    2323#include "state.h"
    24 #include "class_list.h"
    2524
    2625#include "util/loading/load_param.h"
    2726#include "util/loading/factory.h"
    28 #include "util/loading/resource_manager.h"
    2927
    3028#include "graphics_engine.h"
     
    4139#include "network_manager.h"
    4240
    43 #include "preferences.h"
    44 
     41#include "parser/preferences/preferences.h"
     42
     43#include "class_id_DEPRECATED.h"
    4544//! This creates a Factory to fabricate a GameMenu
    46 CREATE_FACTORY(GameMenu, CL_GAME_MENU);
    47 
     45ObjectListDefinitionID(GameMenu, CL_GAME_MENU);
     46CREATE_FACTORY(GameMenu);
    4847
    4948
     
    5150    : GameWorld()
    5251{
    53   this->setClassID(CL_GAME_MENU, "GameMenu");
     52  this->registerObject(this, GameMenu::_objectList);
    5453  this->setName("GameMenu uninitialized");
    5554
     
    191190      image->setForegroundColor(Color( 1,1,1,.6));
    192191
    193       const std::list<BaseObject*>* storyEntities = ClassList::getList(CL_STORY_ENTITY);
    194       std::list<BaseObject*>::const_iterator it;
    195192      bool first = true;
    196       for( it = storyEntities->begin(); it != storyEntities->end(); it++)
     193      for(ObjectList<StoryEntity>::const_iterator it = StoryEntity::objectList().begin();
     194          it != StoryEntity::objectList().end();
     195          ++it)
    197196      {
    198         StoryEntity* se = dynamic_cast<StoryEntity*>(*it);
     197        StoryEntity* se = *it;
    199198        if( se->isContainedInMenu())
    200199        {
    201200
    202           printf("%s\n", se->getMenuScreenshoot().c_str());
     201          PRINTF(3)("Load image %s\n", se->getMenuScreenshoot().c_str());
    203202          OrxGui::GLGuiImageButton* button = new OrxGui::GLGuiImageButton(se->getName(), se->getStoryID(), se->getMenuScreenshoot(), image);
    204203          button->startLevel.connect(this, &GameMenu::startLevel);
Note: See TracChangeset for help on using the changeset viewer.