Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
May 20, 2008, 11:51:33 PM (17 years ago)
Author:
FelixSchulthess
Message:

added full functionality for RadarObjects and two space tomatoes

File:
1 edited

Legend:

Unmodified
Added
Removed
  • code/branches/hud3/src/orxonox/hud/RadarOverlayElement.h

    r1335 r1339  
    4646                Ogre::OverlayManager* om;                               // our one and only overlay manager
    4747                void init();
    48                
     48
    4949        public:
    5050                RadarObject(Ogre::OverlayContainer* container);
    5151                RadarObject(Ogre::OverlayContainer* container, Vector3 pos);
    5252                ~RadarObject();
    53                
     53
     54            bool right_;
    5455                Vector3 pos_;                                                   // position in space
    5556                        Ogre::Real radius_, phi_;                               // position on radar
    56                         bool right_;
    5757                        Ogre::OverlayContainer* container_;
    5858                        Ogre::PanelOverlayElement* panel_;              // the panel used to show the dot
    59                        
     59                        RadarObject* next;                      // next pointer of linked list
     60
    6061                static int count;
    6162        };
     
    6768            Ogre::OverlayContainer* container_;
    6869            Vector3 initialDir_;                        // direction of nose
    69             Vector3 currentDir_;                                       
     70            Vector3 currentDir_;
    7071            Vector3 initialOrth_;                   // direction of normal
    7172            Vector3 currentOrth_;
    7273            Vector3 shipPos_;                       // position of ship
    73            
    74                         RadarObject* tomato_;           
    75            
     74
     75                        RadarObject* firstRadarObject_;         // start of linked list
     76                        RadarObject* lastRadarObject_;          // end of linked list
     77
    7678            Ogre::Real leftRel_, topRel_, dimRel_;  // relative position/dimension
    7779            int left_, top_, dim_;                  // absolute position/dimension
     
    8284            ~RadarOverlayElement();
    8385            void init(Real leftRel, Real topRel, Real dimRel, Ogre::OverlayContainer* container);
    84                         void resize();           
     86                        void resize();
    8587            void update();
    8688            void addObject(Vector3 pos);
     89            void listObjects();
     90            float calcRadius(RadarObject* obj);
     91            float calcPhi(RadarObject* obj);
     92            bool calcRight(RadarObject* obj);
    8793        };
    8894}
Note: See TracChangeset for help on using the changeset viewer.