Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changeset 9869 in orxonox.OLD for trunk/src/world_entities/effects


Ignore:
Timestamp:
Oct 3, 2006, 12:19:30 AM (18 years ago)
Author:
bensch
Message:

orxonox/trunk: merged the new_class_id branche back to the trunk.
merged with command:
svn merge https://svn.orxonox.net/orxonox/branches/new_class_id trunk -r9683:HEAD
no conflicts… puh..

Location:
trunk/src/world_entities/effects
Files:
6 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/world_entities/effects/billboard.cc

    r9406 r9869  
    2626
    2727
    28 
    29 CREATE_FACTORY(Billboard, CL_BILLBOARD);
    30 
     28#include "class_id_DEPRECATED.h"
     29ObjectListDefinitionID(Billboard, CL_BILLBOARD);
     30CREATE_FACTORY(Billboard);
    3131
    3232/**
     
    5757void Billboard::init()
    5858{
    59   this->setClassID(CL_BILLBOARD, "Billboard");
     59  this->registerObject(this, Billboard::_objectList);
    6060  this->setName("Billboard");
    6161
     
    124124  glDisable(GL_LIGHTING);
    125125  glDisable(GL_FOG);
    126  
     126
    127127  glPushMatrix();
    128128
     
    130130  //glTranslatef(0,0,0);
    131131  this->material->select();
    132  
     132
    133133  const PNode* camera = State::getCameraNode();  //!< @todo MUST be different
    134134  Vector cameraPos = camera->getAbsCoor();
     
    141141  h.normalize();
    142142  v.normalize();
    143  
     143
    144144  v *= sizeX;
    145145  h *= sizeY;
     
    165165             this->getAbsCoor().z - h.z + v.z);
    166166  glEnd();
    167  
    168  
     167
     168
    169169  glPopMatrix();
    170  
     170
    171171  glPopAttrib();
    172172}
  • trunk/src/world_entities/effects/billboard.h

    r8255 r9869  
    1313class Billboard : public WorldEntity
    1414{
     15  ObjectListDeclaration(Billboard);
    1516  public:
    1617    Billboard(const TiXmlElement* root = NULL);
  • trunk/src/world_entities/effects/explosion.cc

    r9406 r9869  
    1818#include "explosion.h"
    1919
    20 #include "fast_factory.h"
     20#include "loading/fast_factory.h"
    2121
    2222#include "state.h"
    23 #include "class_list.h"
    2423
    25 #include "box_emitter.h"
    26 #include "sprite_particles.h"
     24#include "particles/box_emitter.h"
     25#include "particles/sprite_particles.h"
    2726
    2827
    2928
    30 
    31 CREATE_FAST_FACTORY_STATIC(Explosion, CL_EXPLOSION);
    32 
     29#include "class_id_DEPRECATED.h"
     30ObjectListDefinitionID(Explosion, CL_EXPLOSION);
     31CREATE_FAST_FACTORY_STATIC(Explosion);
    3332
    3433/**
     
    3736Explosion::Explosion ()
    3837{
    39   this->setClassID(CL_EXPLOSION, "Explosion");
     38  this->registerObject(this, Explosion::_objectList);
    4039  this->toList(OM_DEAD_TICK);
    4140
     
    5958
    6059  /* this is normaly done by World.cc by deleting the ParticleEngine */
    61   if (Explosion::explosionParticles != NULL && ClassList::getList(CL_EXPLOSION)->size() <= 1)
     60  if (Explosion::explosionParticles != NULL && Explosion::objectList().size() <= 1)
    6261     Explosion::explosionParticles = NULL;
    6362}
  • trunk/src/world_entities/effects/explosion.h

    r7125 r9869  
    1515class Explosion : public WorldEntity
    1616{
     17  ObjectListDeclaration(Explosion);
    1718  public:
    1819    static void explode (PNode* position, const Vector& size);
  • trunk/src/world_entities/effects/lightning_bolt.cc

    r9406 r9869  
    2020#include "material.h"
    2121
    22 #include "util/loading/resource_manager.h"
     22#include "sound/resource_sound_buffer.h"
    2323
    2424
    2525
    2626
    27 
    28 CREATE_FACTORY(LightningBolt, CL_LIGHTNING_BOLT);
    29 
     27#include "class_id_DEPRECATED.h"
     28ObjectListDefinitionID(LightningBolt, CL_LIGHTNING_BOLT);
     29CREATE_FACTORY(LightningBolt);
    3030
    3131/**
     
    3434LightningBolt::LightningBolt (const TiXmlElement* root)
    3535{
    36   this->setClassID(CL_LIGHTNING_BOLT, "LightningBolt");
     36  this->registerObject(this, LightningBolt::_objectList);
    3737
    3838  this->toList(OM_COMMON);
     
    5656  this->seedTime = 4.0f;
    5757
    58   this->soundSource = NULL;
    59   this->thunderBuffer = NULL;
    60 
    6158  this->soundSource.setSourceNode(this);
    6259
    63   //load sound
    64   if (this->thunderBuffer != NULL)
    65     ResourceManager::getInstance()->unload(this->thunderBuffer);
    66   this->thunderBuffer = (OrxSound::SoundBuffer*)ResourceManager::getInstance()->load("sound/atmosphere/thunder.wav", WAV);
     60  this->thunderBuffer = OrxSound::ResourceSoundBuffer("sound/atmosphere/thunder.wav");
    6761}
    6862
  • trunk/src/world_entities/effects/lightning_bolt.h

    r7460 r9869  
    22 * @file lightning_bolt.h
    33 * @brief a LightningBolt Projectile
    4  *  Der Effekt soll folgendermaßen funktionieren:
     4 *  Der Effekt soll folgenderman funktionieren:
    55 * -> Ein Partikel mit einer Blitz-Textur soll sehr schnell erscheinen,
    6  * -> während er an Intensität zunimmt soll die Beleuchtung der gerenderten Szene entsprechend zunehmen.
    7  * -> Je mehr Blitze zum gleichen Zeitpunkt sichtbar sind, desto heller soll die Beleuchtung werden, das heißt die Helligkeitszunahme pro Blitz soll Additiv sein.
     6 * -> w�rend er an Intensit� zunimmt soll die Beleuchtung der gerenderten Szene entsprechend zunehmen.
     7 * -> Je mehr Blitze zum gleichen Zeitpunkt sichtbar sind, desto heller soll die Beleuchtung werden, das hei die Helligkeitszunahme pro Blitz soll Additiv sein.
    88 * -> Ein Partikel soll ebenfalls sehr schnell wieder verblassen, dabei soll die Beleuchtung entsprechend der vorhergehenden Zunahme wieder abnehmen (Additiv)
    99 */
     
    2121class LightningBolt : public WorldEntity
    2222{
     23  ObjectListDeclaration(LightningBolt);
    2324  public:
    2425    LightningBolt(const TiXmlElement* root = NULL);
     
    5152
    5253    OrxSound::SoundSource    soundSource;
    53     OrxSound::SoundBuffer*   thunderBuffer;
     54    OrxSound::SoundBuffer    thunderBuffer;
    5455};
    5556
Note: See TracChangeset for help on using the changeset viewer.