Changeset 10674 in orxonox.OLD for branches/vs-enhencements/src/world_entities/space_ships
- Timestamp:
- Jun 6, 2007, 11:10:08 PM (18 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/vs-enhencements/src/world_entities/space_ships/space_ship.cc
r10672 r10674 165 165 this->secWeaponMan.setSlotCount(6); 166 166 167 //this->weaponMan.createWeaponSlot(0, 3.270, 1.028, .155, WTYPE_ALLDIRS | WTYPE_DIRECTIONAL);168 //this->weaponMan.createWeaponSlot(1, 3.270, 1.028, -.155, WTYPE_ALLDIRS | WTYPE_DIRECTIONAL);169 //this->weaponMan.createWeaponSlot(2, 4.385, .063, .876, WTYPE_ALLDIRS | WTYPE_DIRECTIONAL);170 //this->weaponMan.createWeaponSlot(3, 4.385, -.063, -.876, WTYPE_ALLDIRS | WTYPE_DIRECTIONAL);171 //this->weaponMan.createWeaponSlot(4, 1.635, -.612, 2.691, WTYPE_ALLDIRS | WTYPE_DIRECTIONAL);172 //this->weaponMan.createWeaponSlot(5, 1.536, -.612, -2.691, WTYPE_ALLDIRS | WTYPE_DIRECTIONAL);173 //this->weaponMan.createWeaponSlot(6, 1.536, -.612, 3.254, WTYPE_ALLDIRS | WTYPE_DIRECTIONAL);174 //this->weaponMan.createWeaponSlot(7, 1.536, -.612, -3.254, WTYPE_ALLDIRS | WTYPE_DIRECTIONAL);167 this->weaponMan.createWeaponSlot(0, 3.270, 1.028, .155, WTYPE_ALLDIRS | WTYPE_DIRECTIONAL); 168 this->weaponMan.createWeaponSlot(1, 3.270, 1.028, -.155, WTYPE_ALLDIRS | WTYPE_DIRECTIONAL); 169 this->weaponMan.createWeaponSlot(2, 4.385, .063, .876, WTYPE_ALLDIRS | WTYPE_DIRECTIONAL); 170 this->weaponMan.createWeaponSlot(3, 4.385, -.063, -.876, WTYPE_ALLDIRS | WTYPE_DIRECTIONAL); 171 this->weaponMan.createWeaponSlot(4, 1.635, -.612, 2.691, WTYPE_ALLDIRS | WTYPE_DIRECTIONAL); 172 this->weaponMan.createWeaponSlot(5, 1.536, -.612, -2.691, WTYPE_ALLDIRS | WTYPE_DIRECTIONAL); 173 this->weaponMan.createWeaponSlot(6, 1.536, -.612, 3.254, WTYPE_ALLDIRS | WTYPE_DIRECTIONAL); 174 this->weaponMan.createWeaponSlot(7, 1.536, -.612, -3.254, WTYPE_ALLDIRS | WTYPE_DIRECTIONAL); 175 175 176 176 … … 213 213 this->bInit = false; 214 214 215 //loadEnergyShare(.3,.3,.4);216 //loadShield(80, 100, .2, 2);217 // loadHealth(100, 100,0);218 //loadElectronic(40, 50, .7, 3.0);215 loadEnergyShare(.3,.3,.4); 216 loadShield(80, 100, .2, 2); 217 loadHealth(100, 100); 218 loadElectronic(40, 50, .7, 3.0); 219 219 loadReactor(10); 220 220 loadWeapon(10); … … 444 444 { 445 445 446 if( !this->bInit)447 {448 // now get slots from the mount points449 std::map<int, MountPoint*>::iterator it = this->mountPointMap.begin();450 for( ;it != this->mountPointMap.end(); it++)451 {452 WeaponSlot* ws = dynamic_cast<WeaponSlot*>((*it).second->getMount());453 if( ws != NULL && ws->isA(WeaponSlot::staticClassID()))454 {455 int slot = ws->getWeaponSlot();456 // int side = ws->getWeaponSide(); //FIXME / REMOVE: is not used// HACK needed for some weapons (left/right)457 this->getWeaponManager().setSlotPosition(slot, (*it).second->getCenter());458 this->getWeaponManager().setSlotDirection(slot, ws->getRelDir());459 // PRINTF(0)("setting slot %i\n", slot);460 // (*it).second->getCenter().debug();461 }462 }463 this->bInit = true;464 }446 // if( !this->bInit) 447 // { 448 // // now get slots from the mount points 449 // std::map<int, MountPoint*>::iterator it = this->mountPointMap.begin(); 450 // for( ;it != this->mountPointMap.end(); it++) 451 // { 452 // WeaponSlot* ws = dynamic_cast<WeaponSlot*>((*it).second->getMount()); 453 // if( ws != NULL && ws->isA(WeaponSlot::staticClassID())) 454 // { 455 // int slot = ws->getWeaponSlot(); 456 // // int side = ws->getWeaponSide(); //FIXME / REMOVE: is not used// HACK needed for some weapons (left/right) 457 // this->getWeaponManager().setSlotPosition(slot, (*it).second->getCenter()); 458 // this->getWeaponManager().setSlotDirection(slot, ws->getRelDir()); 459 // // PRINTF(0)("setting slot %i\n", slot); 460 // // (*it).second->getCenter().debug(); 461 // } 462 // } 463 // this->bInit = true; 464 // } 465 465 466 466 // Playable::tick(time);
Note: See TracChangeset
for help on using the changeset viewer.