Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
Jul 19, 2009, 3:48:00 PM (15 years ago)
Author:
rgrieder
Message:

Merged orxonox_cast related revisions from core4 back to trunk.

Location:
code/trunk
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • code/trunk

  • code/trunk/src/network/NetworkFunction.h

    r3304 r3325  
    3939#include <boost/static_assert.hpp>
    4040
    41 #include "core/OrxonoxClass.h"
    4241#include "core/Functor.h"
     42#include "core/Identifier.h"
    4343#include "FunctionCallManager.h"
    4444#include "synchronisable/Synchronisable.h"
     
    153153    {
    154154      if ( Synchronisable::getSynchronisable(objectID)!=0 )
    155         (*this->functor_)(dynamic_cast<T*>(Synchronisable::getSynchronisable(objectID)));
     155        (*this->functor_)(orxonox_cast<T*>(Synchronisable::getSynchronisable(objectID)));
    156156    }
    157157    inline void call(uint32_t objectID, const MultiType& mt1)
    158158    {
    159159      if ( Synchronisable::getSynchronisable(objectID)!=0 )
    160         (*this->functor_)(dynamic_cast<T*>(Synchronisable::getSynchronisable(objectID)), mt1);
     160        (*this->functor_)(orxonox_cast<T*>(Synchronisable::getSynchronisable(objectID)), mt1);
    161161    }
    162162    inline void call(uint32_t objectID, const MultiType& mt1, const MultiType& mt2)
    163163    {
    164164      if ( Synchronisable::getSynchronisable(objectID)!=0 )
    165         (*this->functor_)(dynamic_cast<T*>(Synchronisable::getSynchronisable(objectID)), mt1, mt2);
     165        (*this->functor_)(orxonox_cast<T*>(Synchronisable::getSynchronisable(objectID)), mt1, mt2);
    166166    }
    167167    inline void call(uint32_t objectID, const MultiType& mt1, const MultiType& mt2, const MultiType& mt3)
    168168    {
    169169      if ( Synchronisable::getSynchronisable(objectID)!=0 )
    170         (*this->functor_)(dynamic_cast<T*>(Synchronisable::getSynchronisable(objectID)), mt1, mt2, mt3);
     170        (*this->functor_)(orxonox_cast<T*>(Synchronisable::getSynchronisable(objectID)), mt1, mt2, mt3);
    171171    }
    172172    inline void call(uint32_t objectID, const MultiType& mt1, const MultiType& mt2, const MultiType& mt3, const MultiType& mt4)
    173173    {
    174174      if ( Synchronisable::getSynchronisable(objectID)!=0 )
    175         (*this->functor_)(dynamic_cast<T*>(Synchronisable::getSynchronisable(objectID)), mt1, mt2, mt3, mt4);
     175        (*this->functor_)(orxonox_cast<T*>(Synchronisable::getSynchronisable(objectID)), mt1, mt2, mt3, mt4);
    176176    }
    177177    inline void call(uint32_t objectID, const MultiType& mt1, const MultiType& mt2, const MultiType& mt3, const MultiType& mt4, const MultiType& mt5)
    178178    {
    179179      if ( Synchronisable::getSynchronisable(objectID)!=0 )
    180         (*this->functor_)(dynamic_cast<T*>(Synchronisable::getSynchronisable(objectID)), mt1, mt2, mt3, mt4, mt5);
     180        (*this->functor_)(orxonox_cast<T*>(Synchronisable::getSynchronisable(objectID)), mt1, mt2, mt3, mt4, mt5);
    181181    }
    182182   
  • code/trunk/src/network/synchronisable/Synchronisable.cc

    r3304 r3325  
    7373    if (creator)
    7474    {
    75         Synchronisable* synchronisable_creator = dynamic_cast<Synchronisable*>(creator);
     75        Synchronisable* synchronisable_creator = orxonox_cast<Synchronisable*>(creator);
    7676        if (synchronisable_creator && synchronisable_creator->objectMode_)
    7777        {
     
    161161      }
    162162      else
    163         creator = dynamic_cast<BaseObject*>(synchronisable_creator);
     163        creator = orxonox_cast<BaseObject*>(synchronisable_creator);
    164164    }
    165165    assert(getSynchronisable(header.getObjectID())==0);   //make sure no object with this id exists
    166166    BaseObject *bo = id->fabricate(creator);
    167167    assert(bo);
    168     Synchronisable *no = dynamic_cast<Synchronisable *>(bo);
     168    Synchronisable *no = orxonox_cast<Synchronisable*>(bo);
    169169    assert(no);
    170170    no->objectID=header.getObjectID();
Note: See TracChangeset for help on using the changeset viewer.