Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
Apr 23, 2015, 10:44:57 PM (10 years ago)
Author:
landauf
Message:

Loader is now a singleton instead of a static class. fixes issue with statically initialized ClassTreeMask (which again requires a BaseObject-Identifier)

Location:
code/branches/core7/src/orxonox
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • code/branches/core7/src/orxonox/Level.cc

    r9667 r10392  
    6363
    6464            if (this->xmlfile_)
    65                 Loader::unload(this->xmlfile_);
     65                Loader::getInstance().unload(this->xmlfile_);
    6666        }
    6767    }
     
    9595        this->xmlfile_ = new XMLFile(mask, this->xmlfilename_);
    9696
    97         Loader::open(this->xmlfile_);
     97        Loader::getInstance().open(this->xmlfile_);
    9898    }
    9999
  • code/branches/core7/src/orxonox/LevelManager.cc

    r10380 r10392  
    276276                // Load the LevelInfo object from the level file.
    277277                XMLFile file = XMLFile(*it);
    278                 Loader::load(&file, mask, false, true);
     278                Loader::getInstance().load(&file, mask, false, true);
    279279
    280280                // Find the LevelInfo object we've just loaded (if there was one)
     
    284284
    285285                // We don't need the loaded stuff anymore
    286                 Loader::unload(&file);
     286                Loader::getInstance().unload(&file);
    287287
    288288                if(info == NULL)
  • code/branches/core7/src/orxonox/gamestates/GSLevel.cc

    r10362 r10392  
    168168        // call the loader
    169169        startFile_ = new XMLFile(LevelManager::getInstance().getDefaultLevel());
    170         bool loaded = Loader::open(startFile_);
     170        bool loaded = Loader::getInstance().open(startFile_);
    171171
    172172        Core::getInstance().updateLastLevelTimestamp();
     
    177177    void GSLevel::unloadLevel()
    178178    {
    179         Loader::unload(startFile_);
     179        Loader::getInstance().unload(startFile_);
    180180        delete startFile_;
    181181
Note: See TracChangeset for help on using the changeset viewer.