Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
Jun 14, 2008, 7:20:00 PM (16 years ago)
Author:
landauf
Message:
  • added thruster flares
  • used new particle effects
  • enemies with less health emit smoke and fire

!!!! MEDIA UPDATE !!!

File:
1 edited

Legend:

Unmodified
Added
Removed
  • code/trunk/src/orxonox/objects/SpaceShip.cc

    r1564 r1602  
    132132        this->teamNr_ = 0;
    133133        this->health_ = 100;
    134 
    135         COUT(3) << "Info: SpaceShip was loaded" << std::endl;
    136134    }
    137135
     
    209207        node2b->setScale(0.5, 0.5, 0.5);
    210208        tt2_->addToSceneNode(node2b);
     209
     210        this->leftThrusterFlare_.setBillboardSet("Flares/ThrusterFlare1", Vector3(-7.5, -10, -0.5));
     211        this->rightThrusterFlare_.setBillboardSet("Flares/ThrusterFlare1", Vector3(-7.5, 10, -0.5));
     212
     213        Ogre::SceneNode* node2c = this->getNode()->createChildSceneNode(this->getName() + "particle2c");
     214        node2c->setInheritScale(false);
     215        node2c->setScale(2, 2, 2);
     216        node2c->attachObject(this->leftThrusterFlare_.getBillboardSet());
     217        node2c->attachObject(this->rightThrusterFlare_.getBillboardSet());
    211218        // END CREATING THRUSTER
    212219
     
    226233        this->greenNode_->setScale(0.3, 0.3, 0.3);
    227234        // END CREATING BLINKING LIGHTS
     235
     236        this->smoke_.setParticle("Orxonox/smoke5", LODParticle::normal);
     237        this->fire_.setParticle("Orxonox/fire3", LODParticle::normal);
     238        this->attachObject(this->smoke_);
     239        this->attachObject(this->fire_);
    228240
    229241        if (this->isExactlyA(Class(SpaceShip)))
     
    266278        this->crosshairNear_.setVisible(this->isVisible());
    267279        this->crosshairFar_.setVisible(this->isVisible());
     280        this->rightThrusterFlare_.setVisible(this->isVisible());
     281        this->leftThrusterFlare_.setVisible(this->isVisible());
     282        this->smoke_.setVisible(this->isVisible());
     283        this->fire_.setVisible(this->isVisible());
    268284    }
    269285
     
    278294        this->crosshairNear_.setVisible(this->isVisible());
    279295        this->crosshairFar_.setVisible(this->isVisible());
     296        this->rightThrusterFlare_.setVisible(this->isVisible());
     297        this->leftThrusterFlare_.setVisible(this->isVisible());
    280298    }
    281299
     
    385403            this->cam_->tick(dt);
    386404
     405        this->smoke_.setVisible(this->isVisible() && this->health_ < 40);
     406        this->fire_.setVisible(this->isVisible() && this->health_ < 20);
     407
    387408        if (this->redNode_ && this->greenNode_)
    388409        {
Note: See TracChangeset for help on using the changeset viewer.