Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
Jul 2, 2006, 5:30:14 AM (19 years ago)
Author:
bensch
Message:

radar should provide the right data now

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/world_entities/elements/glgui_radar.h

    r8992 r8993  
    99#include "glgui_widget.h"
    1010
     11class PNode;
    1112class WorldEntity;
    1213
     
    2728    virtual ~GLGuiRadar();
    2829
     30    void addEntityList(const std::list<WorldEntity*>* entityList, const Color& color);
     31    void removeEntityList(const std::list<WorldEntity*>* entityList);
     32
    2933    void setRange(float range);
    3034
     35    void setCenterNode(const PNode* center);
    3136    void setUpdateInterval(float updateInterval) { this->_updateInterval = updateInterval; };
    3237    void setAttenuation(Attenuation attenuation);
    3338
     39
    3440    float range() const { return this->_range; }
    3541
     42    void updateRadar();
    3643
    3744    void tick(float dt);
     
    4451
    4552  private:
     53    void init();
     54
     55  private:
    4656    typedef struct
    4757    {
    4858      Color                           dotColor;
    49       const std::list<WorldEntity*>&  entityList;
    50       std::vector<Vector2D>           position;
     59      const std::list<WorldEntity*>*  entityList;
     60      std::vector<Vector2D>           positions;
    5161    }
    5262    DotList;
    5363
    54     std::vector<DotList>        _dotLists;
     64    const PNode*                      _centerNode;
     65    std::vector<DotList>              _dotLists;
    5566
    56     Attenuation                 _attenuation;
    57     float                       _range;
     67    Attenuation                       _attenuation;
     68    float                             _range;
    5869
    5970
    60     float                       _updateInterval;
    61     float                       _timePassed;
     71    float                             _updateInterval;
     72    float                             _timePassed;
    6273  };
    6374}
Note: See TracChangeset for help on using the changeset viewer.