Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
Nov 20, 2009, 5:20:11 PM (15 years ago)
Author:
rgrieder
Message:

Merged particles2 branch to presentation2.

Location:
code/branches/presentation2
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • code/branches/presentation2

  • code/branches/presentation2/src/orxonox/controllers/Controller.h

    r5781 r6107  
    3737    class _OrxonoxExport Controller : public BaseObject
    3838    {
     39        // set friend classes to access setControllableEntity
     40        friend class PlayerInfo;
     41        friend class ControllableEntity;
     42       
    3943        public:
    4044            Controller(BaseObject* creator);
     
    4650                { return this->player_; }
    4751
     52            inline ControllableEntity* getControllableEntity() const
     53                { return this->controllableEntity_; }
     54            virtual void changedControllableEntity() {}
     55
     56        protected:
     57            // don't use this directly, use getPlayer()->startControl(entity) (unless you know exactly what you do)
    4858            inline void setControllableEntity(ControllableEntity* entity)
    4959            {
     
    5464                }
    5565            }
    56             inline ControllableEntity* getControllableEntity() const
    57                 { return this->controllableEntity_; }
    58             virtual void changedControllableEntity() {}
    5966
    60         protected:
    6167            PlayerInfo* player_;
    6268            ControllableEntity* controllableEntity_;
Note: See TracChangeset for help on using the changeset viewer.