Changeset 8976 in orxonox.OLD for trunk/src/util
- Timestamp:
- Jul 1, 2006, 1:05:38 PM (18 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/util/hud.cc
r8975 r8976 19 19 20 20 #include "state.h" 21 #include "debug.h" 21 22 22 23 #include "world_entities/weapons/weapon_manager.h" … … 121 122 122 123 this->updateWeaponManager(); 123 this->updateResolution();124 // this->updateResolution(); 124 125 } 125 126 … … 141 142 if (weapon != NULL) 142 143 { 144 //PRINTF(0)("WEAPON %s::%s in Slots\n", weapon->getClassName(), weapon->getName()); 143 145 weapon->getEnergyWidget()->show(); 144 146 weapon->getEnergyWidget()->setBackgroundColor(Color(.8,.2,.11, 0.1)); … … 161 163 this->resX = State::getResX(); 162 164 this->resY = State::getResY(); 165 166 this->setSize2D(.2 * this->resX, this->resY); 167 163 168 if (this->energyWidget != NULL) 164 169 { … … 167 172 } 168 173 169 this->setSize2D(.2 * this->resX, this->resY);170 174 171 175 std::list<OrxGui::GLGuiWidget*>::iterator weaponWidget; 172 176 float pos = .3; 173 for (weaponWidget = this->weaponsWidgets.begin(); weaponWidget != this->weaponsWidgets.end(); weaponWidget++, pos+=.03) 174 { 175 (*weaponWidget)->setWidgetSize(.02*this->resX, .2 *this->resY); 176 (*weaponWidget)->setAbsCoor2D(pos*this->resX, .75*this->resY); 177 177 for (weaponWidget = this->weaponsWidgets.begin(); weaponWidget != this->weaponsWidgets.end(); weaponWidget++, pos+=.3) 178 { 179 (*weaponWidget)->setAbsCoor2D(pos*this->resX, .9*this->resY); 180 (*weaponWidget)->setWidgetSize(.02*this->resX, .1 *this->resY); 181 (*weaponWidget)->show(); 182 //printf("update thing %s::%s\n", (*weaponWidget)->getClassName(), (*weaponWidget)->getName()); 178 183 } 179 184 }
Note: See TracChangeset
for help on using the changeset viewer.