Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
Nov 30, 2011, 4:09:25 PM (14 years ago)
Author:
willis
Message:

added different Modes, debugging

File:
1 edited

Legend:

Unmodified
Added
Removed
  • code/branches/formation/src/orxonox/controllers/Masterable.h

    r8939 r8953  
    8888      */
    8989      enum Mode {NORMAL,DEFEND,ATTACK};
     90     
    9091      /**
    91         @brief set a mode in formation
    92       */
    93       void setMode(Mode mode);
    94        /**
    95         @brief get the current mode
     92        @brief Sets the new mode. If master, set it for all slaves.
    9693      */
    97       Mode getMode();
    98      
     94      void setMode(Mode val);
     95      inline Mode getMode() const
     96           { return this->mode_; }
     97
    9998    protected:
    10099      bool formationFlight_;
     
    104103      int freedomCount_;
    105104      enum State {SLAVE, MASTER, FREE};
     105     
    106106      State state_;
    107107      std::vector<Masterable*> slaves_;
    108108      Masterable* myMaster_;
     109
     110      Mode mode_;
    109111
    110112      enum SpecificMasterAction {NONE, HOLD, SPIN, TURN180, FOLLOW};
Note: See TracChangeset for help on using the changeset viewer.