diff options
Diffstat (limited to 'source/frontend/StarMainInterface.cpp')
-rw-r--r-- | source/frontend/StarMainInterface.cpp | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/source/frontend/StarMainInterface.cpp b/source/frontend/StarMainInterface.cpp index 8468f7f..e3b28eb 100644 --- a/source/frontend/StarMainInterface.cpp +++ b/source/frontend/StarMainInterface.cpp @@ -57,6 +57,7 @@ #include "StarContainerInteractor.hpp" #include "StarChatBubbleManager.hpp" #include "StarNpc.hpp" +#include "StarCharSelection.hpp" namespace Star { @@ -168,6 +169,14 @@ MainInterface::MainInterface(UniverseClientPtr client, WorldPainterPtr painter, planetName->addChild("planetText", m_planetText); m_paneManager.registerPane(MainInterfacePanes::PlanetText, PaneLayer::Hud, planetName); + auto charSelectionMenu = make_shared<CharSelectionPane>(m_client->playerStorage(), [=]() {}, [=](PlayerPtr mainPlayer) { + m_client->playerStorage()->moveToFront(mainPlayer->uuid()); + m_client->switchPlayer(mainPlayer->name()); + m_paneManager.dismissRegisteredPane(MainInterfacePanes::CharacterSwap); }, [=](Uuid) {}); + charSelectionMenu->setAnchor(PaneAnchor::Center); + + m_paneManager.registerPane(MainInterfacePanes::CharacterSwap, PaneLayer::ModalWindow, charSelectionMenu); + m_nameplatePainter = make_shared<NameplatePainter>(); m_questIndicatorPainter = make_shared<QuestIndicatorPainter>(m_client); m_chatBubbleManager = make_shared<ChatBubbleManager>(); |