Changeset 7739 in orxonox.OLD for trunk/src/story_entities/game_world.cc
- Timestamp:
- May 20, 2006, 11:24:22 AM (19 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/story_entities/game_world.cc
r7723 r7739 67 67 ->completionPlugin(0, OrxShell::CompletorStringArray(Playable::playmodeNames, Playable::PlaymodeCount)); 68 68 69 SHELL_COMMAND(togglePNodeVisibility, GameWorld, GameWorld::togglePNodeVisibility);70 SHELL_COMMAND( toggleBVVisibility, GameWorld, GameWorld::toggleBVVisibility);69 SHELL_COMMAND(togglePNodeVisibility, GameWorld, togglePNodeVisibility); 70 SHELL_COMMAND(showBVLevel, GameWorld, toggleBVVisibility); 71 71 72 72 … … 84 84 this->showPNodes = false; 85 85 this->showBV = false; 86 this->showBVLevel = 3; 86 87 87 88 this->dataXML = NULL; … … 484 485 CDEngine* engine = CDEngine::getInstance(); 485 486 for (unsigned int i = 0; i < this->dataTank->drawLists.size(); ++i) 486 engine->drawBV(State::getObjectManager()->getObjectList(this->dataTank->drawLists[i]) );487 engine->drawBV(State::getObjectManager()->getObjectList(this->dataTank->drawLists[i]), this->showBVLevel); 487 488 } 488 489 … … 533 534 * @brief toggles the bounding volume (BV) visibility 534 535 */ 535 void GameWorld::toggleBVVisibility() 536 { 537 this->showBV = !this->showBV; 536 void GameWorld::toggleBVVisibility(int level) 537 { 538 if( level < 1) 539 this->showBV = false; 540 else 541 { 542 this->showBV = true; 543 this->showBVLevel = level; 544 } 545 538 546 }; 539 547
Note: See TracChangeset
for help on using the changeset viewer.