| 170 | } |
| 171 | |
| 172 | void EditorMode::activate() |
| 173 | { |
| 174 | // Loads the corresponding Gui sheet. |
| 175 | getModeManager().getGui().loadGuiSheet(Gui::editorModeGui); |
| 176 | |
| 177 | // We free the menu scene as it is not required anymore |
| 178 | ODFrameListener::getSingleton().freeMainMenuScene(); |
| 179 | |
| 180 | CEGUI::Window* guiSheet = mRootWindow; |
| 181 | guiSheet->getChild("EditorOptionsWindow")->hide(); |
| 182 | guiSheet->getChild("ConfirmExit")->hide(); |
| 183 | // Hide also the Replay check-box as it doesn't make sense for the editor |
| 184 | guiSheet->getChild("ConfirmExit/SaveReplayCheckbox")->hide(); |
| 185 | guiSheet->getChild("GameChatWindow/GameChatEditBox")->hide(); |
| 186 | |
| 187 | giveFocus(); |
| 188 | |
| 189 | // Stop the game music. |
| 190 | MusicPlayer::getSingleton().stop(); |
| 191 | |
| 192 | // By default, we set the current seat id to the connected player |
| 193 | Player* player = mGameMap->getLocalPlayer(); |
| 194 | getModeManager().getInputManager().mSeatIdSelected = player->getSeat()->getId(); |
| 195 | |
| 196 | refreshGuiSkill(); |
| 197 | |
| 198 | mGameMap->setGamePaused(false); |
| 199 | } |
| 200 | |
| 201 | bool EditorMode::mouseMoved(const OIS::MouseEvent &arg) |
| 202 | { |
nothing calls this directly
no test coverage detected