Changeset 6693 in orxonox.OLD for branches/network/src/world_entities/weapons/weapon.h
- Timestamp:
- Jan 25, 2006, 2:19:46 PM (18 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/network/src/world_entities/weapons/weapon.h
r6512 r6693 16 16 17 17 #include "world_entity.h" 18 #include "count_pointer.h" 19 #include "ammo_container.h" 18 20 19 21 // FORWARD DECLARATION … … 105 107 inline void setCapability(long capabilities) { this->capability = capabilities; }; 106 108 /** @returns the Capabilities of this Weapon */ 107 inline long getCapability() { return this->capability; };109 inline long getCapability() const { return this->capability; }; 108 110 void setProjectileType(ClassID projectile); 109 111 void setProjectileType(const char* projectile); … … 135 137 inline WeaponState getCurrentState() const { return this->currentState; }; 136 138 137 /** @param energyMax the maximum energy the Weapon can have @param energyLoadedMax the maximum energy in the weapon buffers*/138 inline void set MaximumEnergy(float energyMax, float energyLoadedMax) { this->energyMax = energyMax; this->energyLoadedMax = energyLoadedMax; };139 inline float get LoadedEnergyMax() const { return this->energyLoadedMax; };139 /** @param energyMax the maximum energy the Weapon can have */ 140 inline void setEnergyMax(float energyMax) { this->energyMax = energyMax; }; 141 inline float getEnergy() const { return this->energy; }; 140 142 inline float getEnergyMax() const { return this->energyMax; }; 141 inline float getEnergy() const { return this->energy; }; 142 inline float getLoadedEnergy() const { return this->energyLoaded; }; 143 inline void setAmmoContainer(const CountPointer<AmmoContainer>& ammoContainer) { this->ammoContainer = ammoContainer;} 143 144 144 145 void setActionSound(WeaponAction action, const char* soundFile); … … 150 151 151 152 GLGuiWidget* getEnergyWidget(); 152 GLGuiWidget* getLoadedEnergyWidget();153 153 154 154 // FLOW … … 198 198 199 199 // it is all about energy 200 float energy; //!< The energy stored in the weapons secondary buffers (reserve) 201 float energyLoaded; //!< The energy stored in the weapons primary buffers (fire without reload) 200 float energy; //!< The energy stored in the weapons buffers 202 201 float energyMax; //!< The maximal energy that can be stored in the secondary buffers (reserveMax) 203 float energyLoadedMax; //!< The maximal energy that can be stored in the primary buffers202 CountPointer<AmmoContainer> ammoContainer; //!< Pointer to the AmmoContainer this weapon grabs Energy from. 204 203 //! @todo move this to projectile 205 204 float minCharge; //!< The minimal energy to be loaded onto one projectile if chargeable otherwise the power consumed by one projectile … … 207 206 208 207 GLGuiBar* energyWidget; 209 GLGuiBar* energyLoadedWidget;210 208 211 209 ////////////
Note: See TracChangeset
for help on using the changeset viewer.