- Timestamp:
- Dec 4, 2008, 1:20:58 PM (16 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
code/branches/pickups2/src/orxonox/objects/pickup/ShipEquipment.cc
r2324 r2342 16 16 COUT(3) << "swap?" << std::endl; 17 17 return false; 18 18 19 19 return false; 20 20 }; … … 24 24 if(it != Equipment.end()) 25 25 { 26 //it->second->dropped(this->getPlayer());27 26 Equipment.erase (it); 28 27 return true; 29 28 } 30 else 31 return false; 29 return false; 32 30 }; 31 /*void print(std::multimap<std::string, Item*> eut) 32 { 33 std::multimap<std::string,Item*>::iterator it; 34 COUT(3) << "Liste:" << endl; 35 for ( it=eut.begin() ; it != eut.end(); ++it ) 36 COUT(3) << (*it).first << endl; 33 37 38 }*/ 34 39 void ShipEquipment::eraseAll() 35 40 { 36 41 //print(Equipment); 37 42 for (std::multimap<std::string,Item*>::iterator it = Equipment.begin(); it != Equipment.end(); ) 38 43 { 39 44 40 45 (it++)->second->dropped(this->getPlayer()); 41 46 } 47 //print(Equipment); 42 48 } 43 49 … … 47 53 for ( it= getPlayer()->getPickUp().getEquipment().begin() ; it != getPlayer()->getPickUp().getEquipment().end(); it++ ) 48 54 { 49 if((*it).second->getPlayerBaseClass()==item->getPlayerBaseClass()) 55 //if((*it).second->getPlayerBaseClass()==item->getPlayerBaseClass()) 56 if(item->isExactlyA((*it).second->getIdentifier())) 50 57 return false; 51 58 }
Note: See TracChangeset
for help on using the changeset viewer.