Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changeset 3188 for code


Ignore:
Timestamp:
Jun 16, 2009, 2:44:36 PM (15 years ago)
Author:
rgrieder
Message:

Added attachOgreObject and detachOgreObject overloads for Ogre::Camera, Ogre::Entity, Ogre::BillboardSet and Ogre::ParticleSystem.
This saves about nine Ogre includes ;)

Location:
code/branches/pch/src/orxonox/objects
Files:
11 edited

Legend:

Unmodified
Added
Removed
  • code/branches/pch/src/orxonox/objects/weaponsystem/projectiles/BillboardProjectile.cc

    r3185 r3188  
    2929#include "BillboardProjectile.h"
    3030
    31 #include <OgreBillboardSet.h>
    3231#include "core/CoreIncludes.h"
    3332#include "core/GameMode.h"
  • code/branches/pch/src/orxonox/objects/weaponsystem/projectiles/ParticleProjectile.cc

    r3185 r3188  
    2929#include "ParticleProjectile.h"
    3030
    31 #include <OgreParticleSystem.h>
    3231#include <OgreParticleEmitter.h>
    33 
    3432#include "tools/ParticleInterface.h"
    3533#include "core/CoreIncludes.h"
  • code/branches/pch/src/orxonox/objects/worldentities/BigExplosion.cc

    r3186 r3188  
    3030
    3131//#include <sstream>
    32 #include <OgreParticleSystem.h>
    3332
    3433#include "util/Exception.h"
  • code/branches/pch/src/orxonox/objects/worldentities/Billboard.cc

    r3186 r3188  
    2828
    2929#include "Billboard.h"
    30 
    31 #include <OgreBillboardSet.h>
    3230
    3331#include "core/CoreIncludes.h"
  • code/branches/pch/src/orxonox/objects/worldentities/CameraPosition.cc

    r3186 r3188  
    2929#include "CameraPosition.h"
    3030
    31 #include <OgreCamera.h>
    3231#include "core/CoreIncludes.h"
    3332#include "core/XMLPort.h"
  • code/branches/pch/src/orxonox/objects/worldentities/ExplosionChunk.cc

    r3186 r3188  
    2828
    2929#include "ExplosionChunk.h"
    30 
    31 #include <OgreParticleSystem.h>
    3230
    3331#include "core/CoreIncludes.h"
  • code/branches/pch/src/orxonox/objects/worldentities/ParticleEmitter.cc

    r3186 r3188  
    3333
    3434#include "ParticleEmitter.h"
    35 
    36 #include <OgreParticleSystem.h>
    3735
    3836#include "util/Exception.h"
  • code/branches/pch/src/orxonox/objects/worldentities/WorldEntity.cc

    r3186 r3188  
    3030#include "WorldEntity.h"
    3131
     32#include <OgreBillboardSet.h>
     33#include <OgreCamera.h>
     34#include <OgreEntity.h>
     35#include <OgreParticleSystem.h>
     36#include <OgreSceneManager.h>
    3237#include <OgreSceneNode.h>
    33 #include <OgreSceneManager.h>
    3438#include <BulletDynamics/Dynamics/btRigidBody.h>
    3539#include <boost/static_assert.hpp>
     
    468472    //! Attaches an Ogre::MovableObject to this WorldEntity.
    469473    void WorldEntity::attachOgreObject(Ogre::MovableObject* object)
    470     {
    471         this->node_->attachObject(object);
    472     }
     474        { this->node_->attachObject(object); }
     475    void WorldEntity::attachOgreObject(Ogre::BillboardSet* object)
     476        { this->node_->attachObject(object); }
     477    void WorldEntity::attachOgreObject(Ogre::Camera* object)
     478        { this->node_->attachObject(object); }
     479    void WorldEntity::attachOgreObject(Ogre::Entity* object)
     480        { this->node_->attachObject(object); }
     481    void WorldEntity::attachOgreObject(Ogre::ParticleSystem* object)
     482        { this->node_->attachObject(object); }
    473483
    474484    //! Detaches an Ogre::MovableObject from this WorldEntity.
    475485    void WorldEntity::detachOgreObject(Ogre::MovableObject* object)
    476     {
    477         this->node_->detachObject(object);
    478     }
     486        { this->node_->detachObject(object); }
     487    void WorldEntity::detachOgreObject(Ogre::BillboardSet* object)
     488        { this->node_->detachObject(object); }
     489    void WorldEntity::detachOgreObject(Ogre::Camera* object)
     490        { this->node_->detachObject(object); }
     491    void WorldEntity::detachOgreObject(Ogre::Entity* object)
     492        { this->node_->detachObject(object); }
     493    void WorldEntity::detachOgreObject(Ogre::ParticleSystem* object)
     494        { this->node_->detachObject(object); }
    479495
    480496    //! Detaches an Ogre::MovableObject (by string) from this WorldEntity.
  • code/branches/pch/src/orxonox/objects/worldentities/WorldEntity.h

    r3186 r3188  
    173173                { return this->children_; }
    174174
    175             void attachOgreObject(Ogre::MovableObject* object);
    176             void detachOgreObject(Ogre::MovableObject* object);
     175            void attachOgreObject(Ogre::MovableObject*  object);
     176            void attachOgreObject(Ogre::BillboardSet*   object);
     177            void attachOgreObject(Ogre::Camera*         object);
     178            void attachOgreObject(Ogre::Entity*         object);
     179            void attachOgreObject(Ogre::ParticleSystem* object);
     180
     181            void detachOgreObject(Ogre::MovableObject*  object);
     182            void detachOgreObject(Ogre::BillboardSet*   object);
     183            void detachOgreObject(Ogre::Camera*         object);
     184            void detachOgreObject(Ogre::Entity*         object);
     185            void detachOgreObject(Ogre::ParticleSystem* object);
     186
    177187            Ogre::MovableObject* detachOgreObject(const Ogre::String& name);
    178188
  • code/branches/pch/src/orxonox/objects/worldentities/pawns/Spectator.cc

    r3186 r3188  
    2828
    2929#include "Spectator.h"
    30 
    31 #include <OgreBillboardSet.h>
    3230
    3331#include "core/CoreIncludes.h"
  • code/branches/pch/src/orxonox/objects/worldentities/triggers/Trigger.cc

    r3186 r3188  
    2828
    2929#include "Trigger.h"
    30 
    31 #include <OgreBillboardSet.h>
    3230
    3331#include "core/CoreIncludes.h"
Note: See TracChangeset for help on using the changeset viewer.