Changeset 9086 for code/branches/pCuts/src/modules/tetris/TetrisBrick.cc
- Timestamp:
- Apr 14, 2012, 3:32:56 PM (13 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
code/branches/pCuts/src/modules/tetris/TetrisBrick.cc
r9085 r9086 177 177 return NULL; 178 178 } 179 179 //TODO: refactor this function; is not needed if brickstones are added to Tetris::stones_ after collision. 180 180 bool TetrisBrick::contains(TetrisStone* stone) 181 181 { … … 241 241 this->setVelocity(0.0f, 0.0f, 0.0f); 242 242 } 243 243 244 /** 244 245 @brief … … 247 248 void TetrisBrick::releaseStones(TetrisCenterpoint* center) 248 249 { 250 assert(this->tetris_); 249 251 for(unsigned int i = 0; i < brickStones_.size(); i++) 250 252 { 251 //this->brickStones_[i]->detachFromParent(); 252 253 //this->brickStones_[i]->detach(this); 254 //this->brickStones_[i]->attach(center); 253 this->brickStones_[i]->detachFromParent(); 254 this->brickStones_[i]->attachToParent(center); 255 this->brickStones_[i]->setPosition(this->getPosition()+this->tetris_->rotateVector(this->brickStones_[i]->getPosition(),this->rotationCount_ )); 255 256 } 256 257
Note: See TracChangeset
for help on using the changeset viewer.