Changeset 10215 for code/branches/presentationFS14/src/modules/objects/controllers/TeamTargetProxy.h
- Timestamp:
- Jan 31, 2015, 5:31:23 PM (9 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
code/branches/presentationFS14/src/modules/objects/controllers/TeamTargetProxy.h
r10072 r10215 35 35 namespace orxonox 36 36 { 37 38 39 37 /** 38 @brief 39 A controller, that just copies the team and the target of a parent for itself and it's controllable entity. 40 40 41 42 43 44 45 46 47 48 49 50 51 41 Useful for following (and similar) situations: (-> means attached to) 42 turret (rotates) -> some kind of turret base (looks nice) -> spaceship (flies around) 43 The turret has a controller that wants to copy the spaceship's target and team. In this case it doesn't work though, 44 because the turret isn't directly attached to the spaceship. Here's where this controller comes in. Drawback: the base 45 has to be controllable and ticks every second (performance?) 46 */ 47 class _OrxonoxExport TeamTargetProxy : public FormationController, public Tickable 48 { 49 public: 50 TeamTargetProxy(Context* context); 51 virtual ~TeamTargetProxy(); 52 52 53 53 virtual void tick(float dt); 54 54 55 56 57 55 private: 56 bool once_; //!< Flag for executing code in the tick function only once. 57 }; 58 58 } 59 59
Note: See TracChangeset
for help on using the changeset viewer.