Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changeset 9869 for code/branches


Ignore:
Timestamp:
Dec 3, 2013, 9:02:04 PM (11 years ago)
Author:
zifloria
Message:

tried to make particle effects dynamic. Didn't work….

Location:
code/branches/invaders/src/orxonox
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • code/branches/invaders/src/orxonox/graphics/ParticleEmitter.cc

    r9667 r9869  
    4545    RegisterClass(ParticleEmitter);
    4646
    47     ParticleEmitter::ParticleEmitter(Context* context) : StaticEntity(context)
     47    ParticleEmitter::ParticleEmitter(Context* context) : MovableEntity(context)
    4848    {
    4949        RegisterObject(ParticleEmitter);
  • code/branches/invaders/src/orxonox/graphics/ParticleEmitter.h

    r9667 r9869  
    3333
    3434#include <string>
    35 #include "worldentities/StaticEntity.h"
     35#include "worldentities/MovableEntity.h"
    3636
    3737namespace orxonox
    3838{
    39     class _OrxonoxExport ParticleEmitter : public StaticEntity
     39    class _OrxonoxExport ParticleEmitter : public MovableEntity
    4040    {
    4141        public:
  • code/branches/invaders/src/orxonox/worldentities/BigExplosion.cc

    r9868 r9869  
    148148        this->debrisEntity4_->attach(debris4_);
    149149
    150         // particleSpawner is a static entity. It should probably be dynamic, for better explosions.
    151         // effect->SetVelocity(this->getVelocity() + Vector3(rnd(-1, 1), rnd(-1, 1), rnd(-1, 1))*rnd(10,100))
     150        // ///////////////////////
     151        // TODO: particleSpawner is a static entity. It should probably be dynamic, for better explosions.
     152        //
    152153        ParticleSpawner* effect = new ParticleSpawner(this->getContext());
     154        // orxout() << "vel " << getVelocity() << endl;
     155        // effect->setVelocity(Vector3(rnd(-1, 1), rnd(-1, 1), rnd(-1, 1))*rnd(10, 200));
    153156        effect->setDestroyAfterLife(true);
    154157        effect->setSource("Orxonox/explosion2b");
     
    157160
    158161        ParticleSpawner* effect2 = new ParticleSpawner(this->getContext());
     162        // effect2->setVelocity(Vector3(rnd(-1, 1), rnd(-1, 1), rnd(-1, 1))*rnd(10, 200));
    159163        effect2->setDestroyAfterLife(true);
    160164        effect2->setSource("Orxonox/smoke6");
Note: See TracChangeset for help on using the changeset viewer.