- Timestamp:
- May 19, 2006, 4:28:19 AM (19 years ago)
- Location:
- trunk/src/story_entities
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/story_entities/game_world.cc
r7677 r7723 64 64 SHELL_COMMAND(speed, GameWorld, setSpeed) ->describe("set the Speed of the Level"); 65 65 SHELL_COMMAND(playmode, GameWorld, setPlaymode) 66 67 68 69 SHELL_COMMAND _STATIC(togglePNodeVisibility, GameWorld, GameWorld::togglePNodeVisibility);70 SHELL_COMMAND _STATIC(toggleBVVisibility, GameWorld, GameWorld::toggleBVVisibility);66 ->describe("Set the Playmode of the current Level") 67 ->completionPlugin(0, OrxShell::CompletorStringArray(Playable::playmodeNames, Playable::PlaymodeCount)); 68 69 SHELL_COMMAND(togglePNodeVisibility, GameWorld, GameWorld::togglePNodeVisibility); 70 SHELL_COMMAND(toggleBVVisibility, GameWorld, GameWorld::toggleBVVisibility); 71 71 72 72 … … 477 477 /* draw all WorldEntiy groups */ 478 478 for (unsigned int i = 0; i < this->dataTank->drawLists.size(); ++i) 479 this->drawEntityList(State::getObjectManager()->getObjectList(this->dataTank->drawLists[i]));479 this->drawEntityList(State::getObjectManager()->getObjectList(this->dataTank->drawLists[i])); 480 480 481 481 … … 526 526 void GameWorld::togglePNodeVisibility() 527 527 { 528 if (State::getCurrentStoryEntity() != NULL && 529 State::getCurrentStoryEntity()->isA(CL_GAME_WORLD)) 530 { 531 dynamic_cast<GameWorld*>(State::getCurrentStoryEntity())->showPNodes = !dynamic_cast<GameWorld*>(State::getCurrentStoryEntity())->showPNodes; 532 } 533 else 534 PRINTF(2)("The Current Story entity is not a GameWorld\n"); 528 this->showPNodes = !this->showPNodes; 535 529 }; 536 530 … … 541 535 void GameWorld::toggleBVVisibility() 542 536 { 543 if (State::getCurrentStoryEntity() != NULL && 544 State::getCurrentStoryEntity()->isA(CL_GAME_WORLD)) 545 { 546 dynamic_cast<GameWorld*>(State::getCurrentStoryEntity())->showBV = !dynamic_cast<GameWorld*>(State::getCurrentStoryEntity())->showBV; 547 } 548 else 549 PRINTF(2)("The Current Story entity is not a GameWorld\n"); 537 this->showBV = !this->showBV; 550 538 }; 551 539 -
trunk/src/story_entities/game_world.h
r7391 r7723 54 54 /** returns the track path of this world @returns the track path */ 55 55 56 staticvoid togglePNodeVisibility();57 staticvoid toggleBVVisibility();56 void togglePNodeVisibility(); 57 void toggleBVVisibility(); 58 58 59 59 inline void setSky(WorldEntity* sky) { this->dataTank->sky = sky; }
Note: See TracChangeset
for help on using the changeset viewer.