Main Page   Namespace List   Class Hierarchy   Compound List   File List   Compound Members   File Members   Related Pages  

Powerup.h

Go to the documentation of this file.
00001 
00007 #ifndef _POWERUP_H_
00008 #define _POWERUP_H_
00009 
00010 #include "IsoBomb.h"
00011 #include "Entity.h"
00012 #include "CharacterProps.h"
00013 #include "Character.h"
00014 
00015 // Powerup types
00016 const char HP_UP =          'H';
00017 const char SPEED_UP =       'D';
00018 const char BOMBS_UP =       'B';
00019 const char BLAST_UP =       'E';
00020 const char THROW_UP =       'T';
00021 const char HOMING_UP =      'G';
00022 
00028 class Powerup : public Entity {
00029 
00030 public:
00031 
00035     static void initVars( ConfigFile& f );
00036 
00045     Powerup( const Rect& initPos, float height, char powType );
00046 
00050     virtual ~Powerup();
00051 
00058     virtual bool update( float dt );
00059 
00065     virtual void draw( const Point& anchor );
00066     
00072     void affectCharacter( Character* c );
00073 
00079     virtual float getHeight() const;
00080 
00084     char getPowerupType() const;
00085 
00086 private:
00087     Powerup();
00088     Powerup( const Powerup& o );
00089     Powerup& operator = ( const Powerup& rhs );
00090 
00094     static float respawnTime;
00095 
00099     static int virusProb;
00100 
00104     float sinCount;
00105 
00106 private:
00110     char type;
00111 
00115     CharacterProps props;
00116 
00120     bool usedUp;
00121 
00125     bool isVirus;
00126 
00127 };
00128 
00129 #endif

Generated on Tue Mar 4 02:29:25 2003 for SuperIsoBomb by doxygen1.2.18