- Timestamp:
- Jan 17, 2016, 10:29:21 PM (9 years ago)
- Location:
- code/trunk
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
code/trunk
- Property svn:mergeinfo changed
-
code/trunk/src/orxonox/controllers/ActionpointController.h
r11052 r11071 65 65 All the demos are in a file called AITest.oxw. In the menu look for New AI Testing Level. 66 66 */ 67 namespaceAction67 enum class Action 68 68 { 69 enum Value 70 { 71 NONE, FLY, FIGHT, PROTECT, FIGHTALL, ATTACK 72 }; 73 74 } 69 NONE, FLY, FIGHT, PROTECT, FIGHTALL, ATTACK 70 }; 75 71 76 72 struct Point { 77 Action ::Valueaction;73 Action action; 78 74 std::string name; 79 75 Vector3 position; 80 76 bool inLoop; 81 } ; 82 namespace PickupType 83 { 84 enum Value 85 { 86 NONE, DAMAGE, HEALTH, SPEED, PORTAL 87 }; 88 } 77 }; 89 78 90 79 class _OrxonoxExport ActionpointController : public FightingController, public Tickable … … 94 83 ActionpointController(Context* context); 95 84 virtual ~ActionpointController(); 96 virtual void XMLPort(Element& xmlelement, XMLPort::Mode mode) ;85 virtual void XMLPort(Element& xmlelement, XMLPort::Mode mode) override; 97 86 98 87 /** … … 101 90 In tick ship flies and fires. 102 91 */ 103 virtual void tick(float dt) ;92 virtual void tick(float dt) override; 104 93 /** 105 94 @brief … … 186 175 virtual void takeActionpoints (const std::vector<Point>& vector, const std::vector<Point>& loop, bool b); 187 176 188 virtual Action ::ValuegetAction ();177 virtual Action getAction (); 189 178 virtual std::string getActionName(); 190 179 191 void setAction (Action ::Valueaction);192 void setAction (Action ::Valueaction, ControllableEntity* target);193 void setAction (Action ::Valueaction, const Vector3& target);194 void setAction (Action ::Valueaction, const Vector3& target, const Quaternion& orient );180 void setAction (Action action); 181 void setAction (Action action, ControllableEntity* target); 182 void setAction (Action action, const Vector3& target); 183 void setAction (Action action, const Vector3& target, const Quaternion& orient ); 195 184 196 185 virtual bool setWingman(ActionpointController* wingman) … … 210 199 WeakPtr<ActionpointController> myDivisionLeader_; 211 200 //----[Actionpoint information]---- 212 Action ::Valueaction_;201 Action action_; 213 202 std::string protectName_; 214 203 std::string targetName_; 215 std::vector<WeakPtr<WorldEntity> 204 std::vector<WeakPtr<WorldEntity>> actionpoints_; 216 205 float squaredaccuracy_; 217 std::vector<Point > parsedActionpoints_;//<! actionpoints as they are stored here after being parsed from XML218 std::vector<Point > loopActionpoints_;//<! actionpoints that are to be looped206 std::vector<Point> parsedActionpoints_; //<! actionpoints as they are stored here after being parsed from XML 207 std::vector<Point> loopActionpoints_; //<! actionpoints that are to be looped 219 208 bool bInLoop_; //<! variable for addActionpoint method 220 209 bool bLoop_; //<! is state machine looping?
Note: See TracChangeset
for help on using the changeset viewer.