home *** CD-ROM | disk | FTP | other *** search
/ C++ Games Programming / CPPGAMES.ISO / thx / demos / shootout / build / badguy.h < prev    next >
Encoding:
C/C++ Source or Header  |  1995-05-06  |  851 b   |  51 lines

  1. // ---------- badguy.h
  2.  
  3. #ifndef BADGUY_H
  4. #define BADGUY_H
  5.  
  6. #include "shootout.h"
  7.  
  8. class BadGuy : public BitPart {
  9.     virtual short int firegun();
  10.     short int hesitation;
  11.     short int skill;
  12.     short int drawbead();
  13. public:
  14.     BadGuy(char *gfxfile);
  15.     void update_position();
  16.     void initialize_bitpart();
  17.     int iscitizen()
  18.         { return 0; }
  19. };
  20.  
  21. class BadSadie : public BadGuy    {
  22. public:
  23.     BadSadie() : BadGuy("bsadie.gfx")
  24.         { }
  25.     virtual ~BadSadie() { }
  26.     short int firegun()
  27.     {
  28.         play_sound_clip(4);
  29.         set_imageno(8);
  30.         setinterval(5);
  31.         return 1;        // shotgun never misses
  32.     }
  33. };
  34.  
  35. class BadParson : public BadGuy    {
  36. public:
  37.     BadParson() : BadGuy("bparson.gfx")
  38.         { }
  39.     virtual ~BadParson() { }
  40. };
  41.  
  42. class BadDeputy : public BadGuy    {
  43. public:
  44.     BadDeputy() : BadGuy("bdeputy.gfx")
  45.         { }
  46.     virtual ~BadDeputy() { }
  47. };
  48.  
  49. #endif
  50.  
  51.