Logo Search packages:      
Sourcecode: rafkill version File versions  Download package

playerobj.h

#ifndef _player_object_h
#define _player_object_h

#include "shipobj.h"
#include "allegro.h"

class SpaceObject;
class HullObject;
class Booster;
class Section;

class PlayerObject:public ShipObject{
public:
      PlayerObject(int qx, int qy, int _difficulty, HullObject * hnew);
      virtual bool MoveMe( vector< SpaceObject * > * Ammo, vector< SpaceObject * > * fight,Section * onscreen,DATAFILE * snd );

      virtual void Draw(BITMAP * less, ExplosionClass ** _explr, int MAX_EXPLR, int g, int offset );

      virtual bool powerUp();
      virtual int getDifficulty();
      virtual void setDifficulty( int d );
      virtual int getLevel();
      virtual void setLevel( int s );

      virtual bool acceptSpecial();
      virtual void Radar( BITMAP * rad );

      virtual ~PlayerObject();
      
      void Inertia( double & d );
      
      int hull_num;
      int level;
      int difficulty;

private:
      //process: slows object down
      
      //process: forces x and y to be within screen limitations
      void CheckXY();
      
      //process: sets dx=fx, dy=fy
      void MoveD( double & d, double f_max );

      int last_dir;
      int change_frame;
      bool holding_accessory;
      int * shade;
      int shade_color;
      Booster * engine;
};

#endif

Generated by  Doxygen 1.6.0   Back to index