Changeset 4963 in orxonox.OLD for orxonox/trunk/src/world_entities/weapons/turret.h
- Timestamp:
- Jul 28, 2005, 2:43:15 PM (19 years ago)
- File:
-
- 1 copied
Legend:
- Unmodified
- Added
- Removed
-
orxonox/trunk/src/world_entities/weapons/turret.h
r4962 r4963 1 1 /*! 2 @file weapon.h 3 * a weapon that a player can use 4 5 A Player has a list of weapons, that can be choosen to shoot projectiles 6 (projectiles.{cc,h}) at enemies. These weapons can be shooted sequentially 7 or (if able) combined. Therefore you can choose the weapon mode = choose 8 a weapon. 9 10 A weapon is characterized by: 11 o firing-rate: the initial firing rate of a weapon (1/s = Herz) 12 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! 13 o energy-consumption: this determines the energy that has to be used to produce this projectile = costs per projectile 14 15 Furthermore there are some other attributes, that will help to represent a firing 16 weapon in this world: 17 o sound file/ressource: this is a pointer to the sound-file/ressource. however it may be represented 18 o shooting animation 19 2 * @file turret.h 20 3 */ 21 4 22 5 23 #ifndef _T EST_GUN_H24 #define _T EST_GUN_H6 #ifndef _TURRET_H 7 #define _TURRET_H 25 8 26 9 #include "weapon.h" 27 10 28 29 //! a weapon can be left or right sided 30 /** 31 * @todo this will be reset with mirror X/Y/Z 32 */ 33 #define W_LEFT 0 34 #define W_RIGHT 1 35 36 37 class TestGun : public Weapon 11 class Turret : public Weapon 38 12 { 39 13 public: 40 T estGun (WeaponManager* weaponManager, int leftRight);41 virtual ~T estGun();14 Turret (WeaponManager* weaponManager); 15 virtual ~Turret (); 42 16 43 17 virtual void activate(); … … 45 19 46 20 virtual void fire(); 47 virtual void hit (WorldEntity* weapon, Vector* loc);48 21 virtual void destroy(); 49 22 … … 55 28 int leftRight; // this will become an enum 56 29 }; 57 #endif /* _T EST_GUN_H */30 #endif /* _TURRET_H */
Note: See TracChangeset
for help on using the changeset viewer.