Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
Nov 19, 2008, 7:07:36 PM (16 years ago)
Author:
polakma
Message:

added new features to munition.h and weapon.h. tried to fix projectiles (still doesn't compile)

Location:
code/branches/weapon2/src/orxonox/objects/weaponSystem/projectiles
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • code/branches/weapon2/src/orxonox/objects/weaponSystem/projectiles/BillboardProjectile.cc

    r2099 r2232  
    4242        RegisterObject(BillboardProjectile);
    4343
    44         this->billboard_.setBillboardSet("Examples/Flare", ColourValue(1.0, 1.0, 0.5), 1);
    45         this->attachObject(this->billboard_.getBillboardSet());
     44        this->billboard_.setBillboardSet(this->scenemanager_, "Examples/Flare", ColourValue(1.0, 1.0, 0.5), 1);
     45        //this->attachObject(this->billboard_.getBillboardSet());
    4646        this->scale(0.5);
    4747    }
     
    4949    BillboardProjectile::~BillboardProjectile()
    5050    {
    51         if (this->isInitialized() && this->owner_)
    52             this->detachObject(this->billboard_.getBillboardSet());
     51        //if (this->isInitialized() && this->owner_)
     52            //this->detachObject(this->billboard_.getBillboardSet());
    5353    }
    5454
  • code/branches/weapon2/src/orxonox/objects/weaponSystem/projectiles/BillboardProjectile.h

    r2099 r2232  
    4747            virtual void changedVisibility();
    4848
     49            inline Ogre::SceneManager* getSceneManager()
     50            { return this->scenemanager_; }
     51
    4952        private:
    5053            BillboardSet billboard_;
     54            Ogre::SceneManager* scenemanager_;
    5155    };
    5256}
  • code/branches/weapon2/src/orxonox/objects/weaponSystem/projectiles/ParticleProjectile.cc

    r2099 r2232  
    3030#include "ParticleProjectile.h"
    3131
    32 #include "SpaceShip.h"
     32#include "../../worldentities/pawns/SpaceShip.h"
    3333#include "core/CoreIncludes.h"
    3434#include "core/ConfigValueIncludes.h"
     
    4242        RegisterObject(ParticleProjectile);
    4343
    44         this->particles_ = new ParticleInterface("Orxonox/shot2", LODParticle::normal);
     44        this->particles_ = new ParticleInterface(this->getSceneManager(), "Orxonox/shot2", LODParticle::normal);
    4545        this->particles_->addToSceneNode(this->getNode());
    4646        this->particles_->setKeepParticlesInLocalSpace(true);
  • code/branches/weapon2/src/orxonox/objects/weaponSystem/projectiles/Projectile.cc

    r2100 r2232  
    5454        this->smokeTemplateName_ = "Orxonox/smoke4";
    5555
    56         this->setStatic(false);
     56        //this->setStatic(false);
    5757        this->translate(Vector3(55, 0, 0), Ogre::Node::TS_LOCAL);
    5858
Note: See TracChangeset for help on using the changeset viewer.