Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changeset 10562 for code/branches/core7


Ignore:
Timestamp:
Aug 29, 2015, 11:15:28 PM (9 years ago)
Author:
landauf
Message:

removed unnecessary code - this is all done by passing the context to the BaseObject's constructor

Location:
code/branches/core7/src
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • code/branches/core7/src/libraries/core/Namespace.cc

    r10555 r10562  
    105105    void Namespace::loadObjects(BaseObject* object)
    106106    {
    107         object->setNamespace(this);
    108107    }
    109108
  • code/branches/core7/src/libraries/network/synchronisable/Synchronisable.cc

    r10362 r10562  
    182182    no->setClassID(header.getClassID());
    183183    assert(no->contextID_ == header.getContextID());
    184     if( context )
    185     {
    186       BaseObject* boContext = orxonox_cast<BaseObject*>(context);
    187       if (boContext)
    188           bo->setLevel(boContext->getLevel()); // Note: this ensures that the level is known on the client for child objects of the scene (and the scene itself)
    189     }
    190184    //assert(no->classID_ == header.getClassID());
    191185    orxout(verbose, context::network) << "fabricate objectID_: " << no->objectID_ << " classID_: " << no->classID_ << endl;
  • code/branches/core7/src/orxonox/Level.cc

    r10508 r10562  
    134134    {
    135135        this->objects_.push_back(object);
    136         object->setGametype(this->getGametype());
    137136        object->setLevel(this);
    138137    }
  • code/branches/core7/src/orxonox/Scene.cc

    r10555 r10562  
    6262        RegisterObject(Scene);
    6363
    64         this->setScene(StrongPtr<Scene>(this, false), OBJECTID_UNKNOWN);
     64        this->setScene(StrongPtr<Scene>(this, false), this->getObjectID());
    6565        this->bShadows_ = true;
    6666        this->bDebugDrawPhysics_ = false;
     
    316316    {
    317317        this->objects_.push_back(object);
    318         object->setScene(this, this->getObjectID());
    319318    }
    320319
Note: See TracChangeset for help on using the changeset viewer.