/*! @file weapon.h * a weapon that a player can use A Player has a list of weapons, that can be choosen to shoot projectiles (projectiles.{cc,h}) at enemies. These weapons can be shooted sequentially or (if able) combined. Therefore you can choose the weapon mode = choose a weapon. A weapon is characterized by: o firing-rate: the initial firing rate of a weapon (1/s = Herz) o slowdown-factor: this is a factor d: exp(-d*x), d is element of all positive R. it determines how fast the firing-rate will slow down. if no slowdown: d=0, the bigger d is, the faster the weapon will slow down! o energy-consumption: this determines the energy that has to be used to produce this projectile = costs per projectile Furthermore there are some other attributes, that will help to represent a firing weapon in this world: o sound file/ressource: this is a pointer to the sound-file/ressource. however it may be represented o shooting animation */ #ifndef _LASER_CANNON_H #define _LASER_CANNON_H #include "weapon.h" class LaserCannon : public Weapon { ObjectListDeclaration(LaserCannon); public: LaserCannon (const TiXmlElement* root = NULL); virtual ~LaserCannon (); void init(); virtual void loadParams(const TiXmlElement* root); virtual void activate(); virtual void deactivate(); virtual void fire(); private: PNode* objectComponent1; //