Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
Jun 27, 2008, 8:07:29 AM (17 years ago)
Author:
rgrieder
Message:

updated input branch

File:
1 edited

Legend:

Unmodified
Added
Removed
  • code/branches/input/src/orxonox/objects/SpaceShip.h

    r1535 r1629  
    3636#include "Camera.h"
    3737#include "Model.h"
     38#include "RadarViewable.h"
    3839#include "tools/BillboardSet.h"
    3940
    4041namespace orxonox
    4142{
    42     class _OrxonoxExport SpaceShip : public Model
     43    class _OrxonoxExport SpaceShip : public Model, public RadarViewable
    4344    {
    4445        public:
    45          
    46 
    4746            static SpaceShip *getLocalShip();
    4847
     
    5554            virtual void XMLPort(Element& xmlelement, XMLPort::Mode mode);
    5655            virtual void tick(float dt);
     56            virtual void changedVisibility();
     57            virtual void changedActivity();
    5758
    5859            void setCamera(const std::string& camera = "");
     
    6566            void setRotDamp(float value);
    6667            void getFocus();
     68
     69            inline float getMaxSpeed() const
     70                { return this->maxSpeed_; }
     71            inline float getMaxSideAndBackSpeed() const
     72                { return this->maxSideAndBackSpeed_; }
     73            inline float getMaxRotation() const
     74                { return this->maxRotation_; }
     75            inline float getTransAcc() const
     76                { return this->translationAcceleration_; }
     77            inline float getRotAcc() const
     78                { return this->rotationAcceleration_; }
     79            inline float getTransDamp() const
     80                { return this->translationDamping_; }
     81            inline float getRotDamp() const
     82                { return this->rotationDamping_; }
    6783
    6884            static std::string whereAmI();
     
    8399            void doFire();
    84100
    85             float getMaxSpeed();
    86             Vector3 getDir();
    87             Vector3 getOrth();
     101            inline const Vector3& getDir() const
     102                { return this->currentDir_; }
     103            inline const Vector3& getInitialDir() const
     104                { return this->initialDir_; }
     105            inline const Vector3& getOrth() const
     106                { return this->currentOrth_; }
     107            inline const Vector3& getInitialOrth() const
     108                { return this->initialOrth_; }
     109
    88110            Camera* getCamera();
    89111
    90112            int getTeamNr() const
    91113                { return this->teamNr_; }
    92             int getHealth() const
     114            float getHealth() const
    93115                { return this->health_; }
    94116
     
    110132            Vector3 currentOrth_;
    111133            bool bInvertYAxis_;
    112             bool setMouseEventCallback_;
    113134            bool bLMousePressed_;
    114135            bool bRMousePressed_;
     
    118139            std::string camName_;
    119140
     141            ParticleInterface* tt1_;
     142            ParticleInterface* tt2_;
     143            BillboardSet leftThrusterFlare_;
     144            BillboardSet rightThrusterFlare_;
    120145
    121             ParticleInterface* tt_;
     146            Backlight* backlight_;
    122147
    123148            BillboardSet redBillboard_;
     
    126151            Ogre::SceneNode* greenNode_;
    127152            float blinkTime_;
     153
     154            ParticleSpawner* smoke_;
     155            ParticleSpawner* fire_;
    128156
    129157            BillboardSet crosshairNear_;
     
    153181            float mouseY_;
    154182
    155             float emitterRate_;
    156 
    157183        protected:
    158184            bool myShip_;
    159185
    160186            int teamNr_;
    161             int health_;
     187            float health_;
    162188
    163189            static SpaceShip* instance_s;
Note: See TracChangeset for help on using the changeset viewer.