Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changeset 4849 in orxonox.OLD for orxonox/trunk/src/world_entities/weapons


Ignore:
Timestamp:
Jul 13, 2005, 7:03:05 PM (19 years ago)
Author:
bensch
Message:

orxonox/trunk: the crosshair now renders as element2d

Location:
orxonox/trunk/src/world_entities/weapons
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • orxonox/trunk/src/world_entities/weapons/crosshair.cc

    r4838 r4849  
    180180 * draws the crosshair
    181181 */
    182 void Crosshair::draw()
     182void Crosshair::draw() const
    183183{
    184184  GraphicsEngine::storeMatrices();
  • orxonox/trunk/src/world_entities/weapons/crosshair.h

    r4836 r4849  
    88#define _CROSSHAIR_H
    99
     10#include "p_node.h"
     11#include "element_2d.h"
    1012#include "event_listener.h"
    11 #include "p_node.h"
     13
    1214#include "vector.h"
     15
    1316
    1417// FORWARD DEFINITION
     
    1821
    1922//! A class that enables the
    20 class Crosshair : public PNode, public EventListener {
     23class Crosshair : public PNode, public Element2D, public EventListener {
    2124
    2225 public:
     
    3336
    3437  virtual void process(const Event &event);
    35   void tick(float dt);
    36   void draw();
     38  virtual void tick(float dt);
     39  virtual void draw() const;
    3740
    3841 private:
  • orxonox/trunk/src/world_entities/weapons/weapon_manager.cc

    r4837 r4849  
    243243  }
    244244
    245   crosshair->tick(dt);
    246245  crosshair->setRotationSpeed(5);
    247246}
     
    260259      w->draw();
    261260  }
    262   crosshair->draw();
    263261}
    264262
Note: See TracChangeset for help on using the changeset viewer.