home *** CD-ROM | disk | FTP | other *** search
/ AI Game Programming Wisdom / AIGameProgrammingWisdom.iso / SourceCode / 04 Pathfinding and Movement / 05 Hancock / Goal_HitSwitch.h < prev    next >
Encoding:
C/C++ Source or Header  |  2001-08-19  |  422 b   |  24 lines

  1.  
  2.  
  3.  
  4. class Goal_HitSwitch : public Goal, public GoalQueue //for hitting a switch
  5. {
  6. public:
  7.     Goal_HitSwitch( AI* pAI, const PathNode *switchNode_);
  8.  
  9.     virtual ~Goal_HitSwitch();
  10.  
  11.     virtual bool Success();
  12.  
  13.     //replan subgoals
  14.     virtual bool ReplanSubgoals();
  15.  
  16.     // Update the goal
  17.     virtual void Update( float secs_elapsed );
  18.  
  19. protected:
  20.     const Switch *pSwitch;
  21.     bool active;
  22.     const PathNode *switchNode;
  23. };
  24.