Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
Aug 7, 2011, 10:51:54 PM (13 years ago)
Author:
landauf
Message:

added some output (user and internal) throughout the initialization of the game, graphics, and game states

File:
1 edited

Legend:

Unmodified
Added
Removed
  • code/branches/output/src/libraries/core/Core.cc

    r8806 r8830  
    112112        , destructionHelper_(this)
    113113    {
     114        orxout(internal_status) << "initializing Core object..." << endl;
     115
    114116        // Set the hard coded fixed paths
    115117        this->pathConfig_ = new PathConfig();
     
    119121
    120122        // Load modules
     123        orxout(internal_info) << "Loading modules:" << endl;
    121124        const std::vector<std::string>& modulePaths = this->pathConfig_->getModulePaths();
    122125        for (std::vector<std::string>::const_iterator it = modulePaths.begin(); it != modulePaths.end(); ++it)
     
    138141        this->pathConfig_->setConfigurablePaths();
    139142
     143        orxout(internal_info) << "Root path:       " << PathConfig::getRootPathString() << endl;
     144        orxout(internal_info) << "Executable path: " << PathConfig::getExecutablePathString() << endl;
     145        orxout(internal_info) << "Data path:       " << PathConfig::getDataPathString() << endl;
     146        orxout(internal_info) << "Ext. data path:  " << PathConfig::getExternalDataPathString() << endl;
     147        orxout(internal_info) << "Config path:     " << PathConfig::getConfigPathString() << endl;
     148        orxout(internal_info) << "Log path:        " << PathConfig::getLogPathString() << endl;
     149        orxout(internal_info) << "Modules path:    " << PathConfig::getModulePathString() << endl;
     150
    140151        // create a signal handler (only active for Linux)
    141152        // This call is placed as soon as possible, but after the directories are set
     
    153164
    154165        // Manage ini files and set the default settings file (usually orxonox.ini)
     166        orxout(internal_info) << "Loading config:" << endl;
    155167        this->configFileManager_ = new ConfigFileManager();
    156168        this->configFileManager_->setFilename(ConfigFileType::Settings,
     
    158170
    159171        // Required as well for the config values
     172        orxout(internal_info) << "Loading language:" << endl;
    160173        this->languageInstance_ = new Language();
    161174
     
    163176        // possibility to configure everything below here
    164177        RegisterRootObject(Core);
     178        orxout(internal_info) << "configuring Core" << endl;
    165179        this->setConfigValues();
    166180
     
    175189        }
    176190        if (this->bStartIOConsole_)
     191        {
     192            orxout(internal_info) << "creating IO console" << endl;
    177193            this->ioConsole_ = new IOConsole();
     194        }
    178195#endif
    179196
    180197        // creates the class hierarchy for all classes with factories
     198        orxout(internal_info) << "creating class hierarchy" << endl;
    181199        Identifier::createClassHierarchy();
    182200
    183201        // Load OGRE excluding the renderer and the render window
     202        orxout(internal_info) << "creating GraphicsManager:" << endl;
    184203        this->graphicsManager_ = new GraphicsManager(false);
    185204
     
    189208
    190209        // Create singletons that always exist (in other libraries)
     210        orxout(internal_info) << "creating root scope:" << endl;
    191211        this->rootScope_ = new Scope<ScopeID::Root>();
    192212
     
    205225                orxout(internal_error) << "Could not open file for documentation writing" << endl;
    206226        }
     227
     228        orxout(internal_status) << "finished initializing Core object" << endl;
    207229    }
    208230
    209231    void Core::destroy()
    210232    {
     233        orxout(internal_status) << "destroying Core object..." << endl;
     234
    211235        // Remove us from the object lists again to avoid problems when destroying them
    212236        this->unregisterObject();
     
    227251        safeObjectDelete(&dynLibManager_);
    228252        safeObjectDelete(&pathConfig_);
     253
     254        orxout(internal_status) << "finished destroying Core object" << endl;
    229255    }
    230256
     
    310336    void Core::loadGraphics()
    311337    {
     338        orxout(internal_info) << "loading graphics in Core" << endl;
     339       
    312340        // Any exception should trigger this, even in upgradeToGraphics (see its remarks)
    313341        Loki::ScopeGuard unloader = Loki::MakeObjGuard(*this, &Core::unloadGraphics);
     
    351379
    352380        // Create singletons associated with graphics (in other libraries)
     381        orxout(internal_info) << "creating graphics scope:" << endl;
    353382        graphicsScope_ = new Scope<ScopeID::Graphics>();
    354383
    355384        unloader.Dismiss();
     385
     386        orxout(internal_info) << "finished loading graphics in Core" << endl;
    356387    }
    357388
    358389    void Core::unloadGraphics()
    359390    {
     391        orxout(internal_info) << "unloading graphics in Core" << endl;
     392
    360393        safeObjectDelete(&graphicsScope_);
    361394        safeObjectDelete(&guiManager_);
Note: See TracChangeset for help on using the changeset viewer.