Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

source: code/branches/hudelements/src/orxonox/interfaces/RadarViewable.h @ 6717

Last change on this file since 6717 was 6717, checked in by scheusso, 14 years ago

removing some includes

  • Property svn:eol-style set to native
File size: 3.1 KB
Line 
1/*
2 *   ORXONOX - the hottest 3D action shooter ever to exist
3 *                    > www.orxonox.net <
4 *
5 *
6 *   License notice:
7 *
8 *   This program is free software; you can redistribute it and/or
9 *   modify it under the terms of the GNU General Public License
10 *   as published by the Free Software Foundation; either version 2
11 *   of the License, or (at your option) any later version.
12 *
13 *   This program is distributed in the hope that it will be useful,
14 *   but WITHOUT ANY WARRANTY; without even the implied warranty of
15 *   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
16 *   GNU General Public License for more details.
17 *
18 *   You should have received a copy of the GNU General Public License
19 *   along with this program; if not, write to the Free Software
20 *   Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA.
21 *
22 *   Author:
23 *      Reto Grieder
24 *   Co-authors:
25 *      ...
26 *
27 */
28
29#ifndef _RadarViewable_H__
30#define _RadarViewable_H__
31
32#include "OrxonoxPrereqs.h"
33
34#include <string>
35#include <cassert>
36
37#include "util/Math.h"
38#include "core/OrxonoxClass.h"
39
40namespace orxonox
41{
42    /**
43    @brief Interface for receiving window events.
44    */
45    class _OrxonoxExport RadarViewable : virtual public OrxonoxClass
46    {
47    public:
48        enum Shape
49        {
50            Square,
51            Dot,
52            Triangle
53        };
54
55
56    public:
57        RadarViewable();
58        virtual ~RadarViewable();
59
60        inline void setRadarObjectCamouflage(float camouflage)
61            { this->radarObjectCamouflage_ = camouflage; }
62        inline float getRadarObjectCamouflage() const
63            { return this->radarObjectCamouflage_; }
64
65        inline void setRadarObjectColour(const ColourValue& colour)
66            { this->radarObjectColour_ = colour; }
67        inline const ColourValue& getRadarObjectColour() const
68            { return this->radarObjectColour_; }
69
70        void setRadarObjectDescription(const std::string& str);
71        inline const std::string& getRadarObjectDescription() const
72            { return this->radarObjectDescription_; }
73
74        inline void setRadarVisibility(bool b)
75            { this->bVisibility_ = b; }
76        inline bool getRadarVisibility() const
77            { return this->bVisibility_; }
78
79        virtual const WorldEntity* getWorldEntity() const = 0;
80
81        const Vector3& getRVWorldPosition() const;
82        Vector3 getRVOrientedVelocity() const;
83
84        inline void setRadarObjectShape(Shape shape)
85            { this->radarObjectShape_ = shape; }
86        inline Shape getRadarObjectShape() const
87            { return this->radarObjectShape_; }
88
89
90        bool isHumanShip_;
91        inline const std::string& getUniqueId()
92        {
93            return this->uniqueId_;
94        }
95        //friend class Map;
96
97    private:
98        void validate(const WorldEntity* object) const;
99        bool bVisibility_;
100        //Map
101        std::string uniqueId_;
102
103
104        //Radar
105        float radarObjectCamouflage_;
106        Shape radarObjectShape_;
107        std::string radarObjectDescription_;
108        ColourValue radarObjectColour_;
109
110    };
111}
112
113#endif /* _RadarViewable_H__ */
Note: See TracBrowser for help on using the repository browser.