Changeset 10791 for code/branches/fabienHS15/src/modules
- Timestamp:
- Nov 9, 2015, 5:55:42 PM (9 years ago)
- Location:
- code/branches/fabienHS15/src/modules
- Files:
-
- 15 edited
Legend:
- Unmodified
- Added
- Removed
-
code/branches/fabienHS15/src/modules/overlays/hud/HUDWeaponMode.cc
r10739 r10791 73 73 this->textOverlayLeft_ = new OverlayText(this->getContext()); 74 74 assert(this->textOverlayLeft_.get()); 75 this->textOverlayLeft_->setCaption("? ??");75 this->textOverlayLeft_->setCaption("?"); 76 76 textOverlayLeft_->setPickPoint(Vector2(0.0f,0.0f)); 77 77 textOverlayLeft_->setVisible(true); … … 83 83 84 84 this->textOverlayRight_ = new OverlayText(this->getContext()); 85 assert(this->textOverlay Left_.get());86 this->textOverlayRight_->setCaption("? ??");85 assert(this->textOverlayRight_.get()); 86 this->textOverlayRight_->setCaption("?"); 87 87 textOverlayRight_->setPickPoint(Vector2(0.0f,0.0f)); 88 88 textOverlayRight_->setVisible(true); … … 93 93 textOverlayRight_->setZOrder(600); 94 94 95 materialNameState_ = "Orxonox/WSHUD_ Reloading";95 materialNameState_ = "Orxonox/WSHUD_Empty"; 96 96 97 97 overlayElementReplenish_->setMaterialName("Orxonox/WSHUD_Replenish"); … … 155 155 materialNameState_ = "Orxonox/WSHUD_Empty"; 156 156 } 157 } 158 159 if (munition->isA(Class(ReplenishingMunition)))160 {161 ReplenishingMunition* replenishingMunition = dynamic_cast<ReplenishingMunition*>(munition); 162 163 if (replenishingMunition->canAddMunition(1))164 {165 float progress = 1.0f - replenishingMunition->getProgress();166 overlayElementReplenish_->setDimensions(1.0f,progress);167 }168 else169 {170 overlayElementReplenish_->setDimensions(1.0f,1.0f);157 158 if (munition->isA(Class(ReplenishingMunition))) 159 { 160 ReplenishingMunition* replenishingMunition = dynamic_cast<ReplenishingMunition*>(munition); 161 162 if (replenishingMunition->canAddMunition(1)) 163 { 164 float progress = 1.0f - replenishingMunition->getProgress(); 165 overlayElementReplenish_->setDimensions(1.0f,progress); 166 } 167 else 168 { 169 overlayElementReplenish_->setDimensions(1.0f,1.0f); 170 } 171 171 } 172 172 } -
code/branches/fabienHS15/src/modules/weapons/munitions/FusionMunition.cc
r10713 r10791 34 34 #include "FusionMunition.h" 35 35 #include "core/CoreIncludes.h" 36 #include "core/XMLPort.h" 36 37 37 38 namespace orxonox … … 56 57 this->reloadTime_ = 0.5f; 57 58 } 59 60 void FusionMunition::XMLPort(Element& xmlelement, XMLPort::Mode mode) 61 { 62 SUPER(FusionMunition, XMLPort, xmlelement, mode); 63 } 58 64 } -
code/branches/fabienHS15/src/modules/weapons/munitions/FusionMunition.h
r9667 r10791 53 53 FusionMunition(Context* context); 54 54 virtual ~FusionMunition() {} 55 virtual void XMLPort(Element& xmlelement, XMLPort::Mode mode); 55 56 }; 56 57 } -
code/branches/fabienHS15/src/modules/weapons/munitions/GravityBombMunition.cc
r10713 r10791 7 7 #include "GravityBombMunition.h" 8 8 #include "core/CoreIncludes.h" 9 #include "core/XMLPort.h" 9 10 10 11 namespace orxonox … … 27 28 } 28 29 30 void GravityBombMunition::XMLPort(Element& xmlelement, XMLPort::Mode mode) 31 { 32 SUPER(GravityBombMunition, XMLPort, xmlelement, mode); 33 } 29 34 } 30 35 -
code/branches/fabienHS15/src/modules/weapons/munitions/GravityBombMunition.h
r10622 r10791 28 28 GravityBombMunition(Context* context); 29 29 virtual ~GravityBombMunition() {} 30 virtual void XMLPort(Element& xmlelement, XMLPort::Mode mode); 30 31 }; 31 32 -
code/branches/fabienHS15/src/modules/weapons/munitions/IceMunition.cc
r10715 r10791 34 34 #include "IceMunition.h" 35 35 #include "core/CoreIncludes.h" 36 #include "core/XMLPort.h" 36 37 37 38 namespace orxonox … … 54 55 this->reloadTime_ = 0.5f; 55 56 } 57 58 void IceMunition::XMLPort(Element& xmlelement, XMLPort::Mode mode) 59 { 60 SUPER(IceMunition, XMLPort, xmlelement, mode); 61 } 56 62 } -
code/branches/fabienHS15/src/modules/weapons/munitions/IceMunition.h
r10629 r10791 53 53 IceMunition(Context* context); 54 54 virtual ~IceMunition() {} 55 virtual void XMLPort(Element& xmlelement, XMLPort::Mode mode); 55 56 }; 56 57 } -
code/branches/fabienHS15/src/modules/weapons/munitions/LaserMunition.cc
r10724 r10791 34 34 #include "LaserMunition.h" 35 35 #include "core/CoreIncludes.h" 36 #include "core/XMLPort.h" 36 37 37 38 namespace orxonox … … 53 54 54 55 this->replenishInterval_ = 0.5f; 55 this->replenish MunitionAmount_ = 1;56 this->replenishAmount_ = 1; 56 57 57 58 this->reloadTime_ = 0.5f; 58 59 } 60 61 void LaserMunition::XMLPort(Element& xmlelement, XMLPort::Mode mode) 62 { 63 SUPER(LaserMunition, XMLPort, xmlelement, mode); 64 } 59 65 } -
code/branches/fabienHS15/src/modules/weapons/munitions/LaserMunition.h
r10688 r10791 53 53 LaserMunition(Context* context); 54 54 virtual ~LaserMunition() {} 55 virtual void XMLPort(Element& xmlelement, XMLPort::Mode mode); 55 56 }; 56 57 } -
code/branches/fabienHS15/src/modules/weapons/munitions/LightningMunition.cc
r10713 r10791 34 34 #include "LightningMunition.h" 35 35 #include "core/CoreIncludes.h" 36 #include "core/XMLPort.h" 36 37 37 38 namespace orxonox … … 54 55 this->reloadTime_ = 0.5f; 55 56 } 57 58 void LightningMunition::XMLPort(Element& xmlelement, XMLPort::Mode mode) 59 { 60 SUPER(LightningMunition, XMLPort, xmlelement, mode); 61 } 56 62 } -
code/branches/fabienHS15/src/modules/weapons/munitions/LightningMunition.h
r10688 r10791 53 53 LightningMunition(Context* context); 54 54 virtual ~LightningMunition() {} 55 virtual void XMLPort(Element& xmlelement, XMLPort::Mode mode); 55 56 }; 56 57 } -
code/branches/fabienHS15/src/modules/weapons/munitions/RocketMunition.cc
r10715 r10791 34 34 #include "RocketMunition.h" 35 35 #include "core/CoreIncludes.h" 36 #include "core/XMLPort.h" 36 37 37 38 namespace orxonox … … 54 55 this->reloadTime_ = 0.5f; 55 56 } 57 58 void RocketMunition::XMLPort(Element& xmlelement, XMLPort::Mode mode) 59 { 60 SUPER(RocketMunition, XMLPort, xmlelement, mode); 61 } 56 62 } -
code/branches/fabienHS15/src/modules/weapons/munitions/RocketMunition.h
r9667 r10791 53 53 RocketMunition(Context* context); 54 54 virtual ~RocketMunition() {} 55 virtual void XMLPort(Element& xmlelement, XMLPort::Mode mode); 55 56 }; 56 57 } -
code/branches/fabienHS15/src/modules/weapons/munitions/SplitMunition.cc
r10715 r10791 34 34 #include "SplitMunition.h" 35 35 #include "core/CoreIncludes.h" 36 #include "core/XMLPort.h" 36 37 37 38 namespace orxonox … … 54 55 this->reloadTime_ = 0.5f; 55 56 } 57 58 void SplitMunition::XMLPort(Element& xmlelement, XMLPort::Mode mode) 59 { 60 SUPER(SplitMunition, XMLPort, xmlelement, mode); 61 } 56 62 } -
code/branches/fabienHS15/src/modules/weapons/munitions/SplitMunition.h
r10629 r10791 53 53 SplitMunition(Context* context); 54 54 virtual ~SplitMunition() {} 55 virtual void XMLPort(Element& xmlelement, XMLPort::Mode mode); 55 56 }; 56 57 }
Note: See TracChangeset
for help on using the changeset viewer.