Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
Aug 25, 2013, 9:08:42 PM (11 years ago)
Author:
landauf
Message:

merged core6 back to trunk

Location:
code/trunk
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • code/trunk

  • code/trunk/src/libraries/core/BaseObject.cc

    r8858 r9667  
    3939#include "Event.h"
    4040#include "EventIncludes.h"
    41 #include "Iterator.h"
    4241#include "Template.h"
    4342#include "XMLFile.h"
     
    4544#include "XMLPort.h"
    4645#include "command/Functor.h"
     46#include "object/Iterator.h"
     47
     48#include "class/OrxonoxInterface.h" // we include this only to include OrxonoxInterface.h at least once in core to keep MSVC happy...
    4749
    4850namespace orxonox
    4951{
    50     CreateFactory(BaseObject);
     52    RegisterClass(BaseObject);
    5153
    5254    /**
    5355        @brief Constructor: Registers the object in the BaseObject-list.
    5456    */
    55     BaseObject::BaseObject(BaseObject* creator) : bInitialized_(false)
    56     {
    57         RegisterRootObject(BaseObject);
     57    BaseObject::BaseObject(Context* context) : bInitialized_(false)
     58    {
     59        RegisterObject(BaseObject);
    5860
    5961        this->bInitialized_ = true;
     
    6870        this->mainStateFunctor_ = 0;
    6971
     72        if (context)
     73            this->setContext(context);
     74
     75        BaseObject* creator = orxonox_cast<BaseObject*>(context);
    7076        this->setCreator(creator);
    7177        if (this->creator_)
     
    199205        {
    200206            this->networkTemplateNames_.insert(temp->getLink());
    201            
     207
    202208            Template* link;
    203209            assert(!(link = Template::getTemplate(temp->getLink())) || !link->isLink());
Note: See TracChangeset for help on using the changeset viewer.