Logo Search packages:      
Sourcecode: race version File versions

ai.h

#ifndef race_car_ai
#define race_car_ai

#include "attractor.h"

class Car_AI : public Car
{
 private:
      short atr_num;
      char tmp_wa;

      bool stays_on_road();
      void avoid_collisions();

      bool road( float, float );

      char collision_counter;
      float collision_timer;

 protected:
      char ai_id;

 public:
      Car_AI(float x, float y, char _id, char _ai_id );
      virtual ~Car_AI();
   
      virtual void show(int center_x, int center_y );
      virtual void update(float);

      virtual bool is_ai() { return true; }
      virtual bool is_player() { return false; }

      virtual int get_car_id(){ return id; }

      void update_frame(int);

      virtual void update_wanted_dir();
      virtual void update_extras();
      virtual void reset_special();

      void update_object_speed();

      Attractor pit_attr;
};

#endif // header_ai 

Generated by  Doxygen 1.6.0   Back to index