- Timestamp:
- Nov 26, 2008, 7:48:26 PM (15 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
code/branches/pickups2/src/orxonox/objects/pickup/Turbo.cc
r2227 r2289 19 19 this->duration_ = 0; 20 20 this->accboost_ = 1; 21 this->rotacc_= 0; 21 22 } 22 23 … … 32 33 XMLPortParam(Turbo, "duration", setDuration, getDuration, xmlelement, mode); 33 34 XMLPortParam(Turbo, "accboost", setAccBoost, getAccBoost, xmlelement, mode); 35 XMLPortParam(Turbo, "rotacc", setRotAcc, getRotAcc, xmlelement, mode); 36 34 37 } 35 38 … … 53 56 ship->setMaxSpeed( ship->getMaxSpeed() - this->boost_); 54 57 ship->setTransAcc( ship->getTransAcc()/this->accboost_); 58 ship->setMaxRotation( ship->getMaxRotation()-this->rotacc_); 59 ship->setRotAcc( ship->getRotAcc()-this->rotacc_); 55 60 COUT(3)<<"PickUp Timer expired"<<std::endl; 56 61 } … … 60 65 ship->setMaxSpeed( ship->getMaxSpeed() + this->boost_); 61 66 ship->setTransAcc( ship->getTransAcc()*this->accboost_); 67 ship->setMaxRotation( ship->getMaxRotation()+this->rotacc_); 68 ship->setRotAcc( ship->getRotAcc()+this->rotacc_); 62 69 if( this->duration_ != 0) 63 70 { … … 72 79 if (this->duration_ == 0) 73 80 { 74 //player->Equipment.erase ( std::pair<std::string, Item*>(this->itemname,this) ); 81 if(remove(player)==true); 82 { 75 83 SpaceShip* ship = dynamic_cast <SpaceShip*>(player); 76 84 this->unsetSpeedBoost(ship); 85 } 77 86 } 78 87 return true;
Note: See TracChangeset
for help on using the changeset viewer.