Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
Dec 28, 2008, 7:21:17 PM (16 years ago)
Author:
rgrieder
Message:
  • Removed a const_const that could be easily replaced
  • getScene()→getSceneManager() is non zero again in dedicated mode

—> PLEASE ALWAYS USE Core::showsGraphics() TO IDENTIFY EXACTLY THAT, NOT this→getScene()→getSceneManager().

Location:
code/branches/presentation/src/orxonox/objects/worldentities
Files:
5 edited

Legend:

Unmodified
Added
Removed
  • code/branches/presentation/src/orxonox/objects/worldentities/Backlight.cc

    r2500 r2537  
    214214                this->update_trailmaterial();
    215215                if (this->ribbonTrail_)
    216                     this->ribbonTrail_->addNode(const_cast<Ogre::SceneNode*>(this->getNode()));
     216                    this->ribbonTrail_->addNode(this->node_);
    217217            }
    218218        }
  • code/branches/presentation/src/orxonox/objects/worldentities/Billboard.cc

    r2485 r2537  
    3434#include "core/CoreIncludes.h"
    3535#include "core/XMLPort.h"
     36#include "core/Core.h"
    3637#include "objects/Scene.h"
    3738
     
    8081        if (!this->billboard_.getBillboardSet())
    8182        {
    82             if (this->getScene() && this->getScene()->getSceneManager())
     83            if (this->getScene() && Core::showsGraphics())
    8384            {
    8485                this->billboard_.setBillboardSet(this->getScene()->getSceneManager(), this->material_, this->colour_, 1);
     
    9798        {
    9899/*
    99             if (this->getScene() && this->getScene()->getSceneManager() && (this->material_ != ""))
     100            if (this->getScene() && Core::showsGraphics() && (this->material_ != ""))
    100101            {
    101102                this->billboard_.setBillboardSet(this->getScene()->getSceneManager(), this->material_, this->colour_, 1);
  • code/branches/presentation/src/orxonox/objects/worldentities/ExplosionChunk.cc

    r2485 r2537  
    4747        RegisterObject(ExplosionChunk);
    4848
    49         if (!this->getScene() || !this->getScene()->getSceneManager())
     49        if (!this->getScene() || !Core::showsGraphics() || !this->getScene()->getSceneManager())
    5050            ThrowException(AbortLoading, "Can't create ExplosionChunk, no scene or no scene manager given.");
    5151
  • code/branches/presentation/src/orxonox/objects/worldentities/ParticleEmitter.cc

    r2497 r2537  
    107107        }
    108108
    109         if (this->getScene() && this->getScene()->getSceneManager())
     109        if (Core::showsGraphics() && this->getScene() && this->getScene()->getSceneManager())
    110110        {
    111111            try
  • code/branches/presentation/src/orxonox/objects/worldentities/triggers/Trigger.cc

    r2500 r2537  
    3636#include "core/ConsoleCommand.h"
    3737#include "core/XMLPort.h"
     38#include "core/Core.h"
    3839#include "objects/Scene.h"
    3940
     
    6667//    this->bUpdating_ = false;
    6768
    68     if (this->getScene() && this->getScene()->getSceneManager())
     69    if (this->getScene() && Core::showsGraphics())
    6970    {
    7071      this->debugBillboard_.setBillboardSet(this->getScene()->getSceneManager(), "Examples/Flare", ColourValue(1.0, 0.0, 0.0), 1);
Note: See TracChangeset for help on using the changeset viewer.