Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
May 9, 2011, 2:59:07 PM (13 years ago)
Author:
decryphe
Message:
  • Moved handling of blur effect from Engine.cc to SpaceShip.cc.
  • Implemented handling of multiple engines per SpaceShip, so that in future it would be possible to turn single engines on/off individually (for example if one gets destroyed on a big ship).
  • Updated some pointers accessing the single Engine of a SpaceShip to ask the SpaceShip itself instead for data.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • code/branches/bigships/src/orxonox/items/Engine.h

    r8079 r8426  
    5454            inline SpaceShip* getShip() const
    5555                { return this->ship_; }
     56
     57                        inline void setRelativePosition(const Vector3 &position)
     58                                { this->relativePosition_ = position; }
     59                        inline Vector3& getRelativePosition()
     60                                { return this->relativePosition_; }
    5661
    5762            inline void setBoostFactor(float factor)
     
    119124                { this->speedMultiply_=speedMultiply; }
    120125
     126                       
     127            inline void setEngineTemplate(const std::string& temp)
     128                { this->engineTemplate_ = temp; this->loadEngineTemplate(); }
     129            inline const std::string& getEngineTemplate() const
     130                { return this->engineTemplate_; }
     131
    121132        protected:
    122133            virtual std::vector<PickupCarrier*>* getCarrierChildren(void) const
    123134                { return new std::vector<PickupCarrier*>(); }
    124135            virtual PickupCarrier* getCarrierParent(void) const;
     136                       
     137            void loadEngineTemplate();
    125138
    126139        private:
    127140            void registerVariables();
    128141            void networkcallback_shipID();
    129             void changedEnableMotionBlur();
     142
     143                        std::string engineTemplate_;
    130144
    131145            SpaceShip* ship_;
    132146            unsigned int shipID_;
     147                        Vector3 relativePosition_;
    133148
    134149            float boostFactor_;
     
    148163            float accelerationLeftRight_;
    149164            float accelerationUpDown_;
    150 
    151             Shader* boostBlur_;
    152             float blurStrength_;
    153             bool bEnableMotionBlur_;
    154165    };
    155166}
Note: See TracChangeset for help on using the changeset viewer.