Changeset 11305 for code/branches/HUD_HS16/src/modules/overlays
- Timestamp:
- Nov 21, 2016, 4:18:45 PM (8 years ago)
- Location:
- code/branches/HUD_HS16/src/modules/overlays/hud
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
code/branches/HUD_HS16/src/modules/overlays/hud/HUDPickupItem.cc
r11295 r11305 65 65 } 66 66 67 void initializeMaterial(const std::string& s)67 void HUDPickupItem::initializeMaterial(const std::string& s) 68 68 { 69 69 overlayElement_->setMaterialName(s); 70 70 } 71 71 72 void printHello()72 void HUDPickupItem::printHello() 73 73 { 74 74 orxout() << "lets say hello" << endl; -
code/branches/HUD_HS16/src/modules/overlays/hud/HUDPickupItem.h
r11295 r11305 53 53 } 54 54 55 #endif /* _HUDWeapon_H__ */55 #endif -
code/branches/HUD_HS16/src/modules/overlays/hud/HUDPickupSystem.cc
r11295 r11305 37 37 #include "pickup/Pickup.h" 38 38 #include "HUDPickupItem.h" 39 #include "pickup/PickupManager.h" 39 40 40 41 namespace orxonox … … 53 54 this->background_->addChild(overlayElement_); 54 55 56 PickupManager::getInstance().setPickupSystem(this); 55 57 } 56 58 … … 65 67 //TODO: XMLPort 66 68 67 void HUDPickupSystem::updatePickupList(std::vector< WeakPtr<Pickup>> picks)69 void HUDPickupSystem::updatePickupList(std::vector<Pickupable*> picks) 68 70 { 69 for(Pickup * p : picks)71 for(Pickupable* p : picks) 70 72 { 71 73 HUDPickupItem* item = new HUDPickupItem(this->getContext()); 72 // item->initializeMaterial(p->getRepresentationName());74 item->initializeMaterial(((Pickup*)p)->getRepresentationName()); 73 75 item->printHello(); 74 76 } -
code/branches/HUD_HS16/src/modules/overlays/hud/HUDPickupSystem.h
r11293 r11305 26 26 * 27 27 */ 28 29 30 #ifndef _HUDPickupSystem_H__ 31 #define _HUDPickupSystem_H__ 32 28 33 #include "overlays/OverlaysPrereqs.h" 29 34 … … 58 63 // virtual void positionChanged() override; 59 64 // virtual void sizeChanged() override; 65 void updatePickupList(std::vector<Pickupable*> picks); 60 66 private: 61 void updatePickupList(std::vector<WeakPtr<Pickup>> picks);62 67 void createPickupList(); 63 68 void destroyAll(); … … 69 74 }; 70 75 } 76 77 #endif
Note: See TracChangeset
for help on using the changeset viewer.