Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
Nov 25, 2008, 1:14:19 AM (16 years ago)
Author:
landauf
Message:

The SpaceShips HUD is working again (Speedbar and Radar)

Location:
code/branches/objecthierarchy2/src/orxonox/objects/worldentities/pawns
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • code/branches/objecthierarchy2/src/orxonox/objects/worldentities/pawns/Pawn.cc

    r2171 r2256  
    6161        this->weaponSystem_->getWeaponSetPointer(0)->getWeaponSlotPointer(0)->setAmmoType(true);
    6262        */
     63
     64        this->setRadarObjectColour(ColourValue::Red);
     65        this->setRadarObjectShape(RadarViewable::Dot);
    6366
    6467        this->registerVariables();
  • code/branches/objecthierarchy2/src/orxonox/objects/worldentities/pawns/Pawn.h

    r2098 r2256  
    3333
    3434#include "objects/worldentities/ControllableEntity.h"
     35#include "objects/RadarViewable.h"
    3536
    3637namespace orxonox
    3738{
    38     class _OrxonoxExport Pawn : public ControllableEntity
     39    class _OrxonoxExport Pawn : public ControllableEntity, public RadarViewable
    3940    {
    4041        public:
     
    7879            virtual void postSpawn();
    7980
     81            inline const WorldEntity* getWorldEntity() const
     82                { return (WorldEntity*)this; }
     83
    8084        protected:
    8185            virtual void spawn();
  • code/branches/objecthierarchy2/src/orxonox/objects/worldentities/pawns/SpaceShip.cc

    r2254 r2256  
    229229        }
    230230    }
     231
     232    void SpaceShip::setEngine(Engine* engine)
     233    {
     234        this->engine_ = engine;
     235        if (engine && engine->getShip() != this)
     236            engine->addToSpaceShip(this);
     237    }
    231238}
  • code/branches/objecthierarchy2/src/orxonox/objects/worldentities/pawns/SpaceShip.h

    r2254 r2256  
    5858            virtual void boost();
    5959
     60            void setEngine(Engine* engine);
     61            inline Engine* getEngine() const
     62                { return this->engine_; }
     63
    6064            void setMaxRotation(const Degree& value)
    6165                { this->maxRotation_ = value; }
Note: See TracChangeset for help on using the changeset viewer.