Stop random starting of overworld after multiplayer kartselection
Since the variable m_from_overworld wasn't being initialized, its value could randomly be true. It was also not being set when clicking multiplayer in main menu. Making it initialize to false as well as setting it when clicking multiplayer to be on the safe side. git-svn-id: svn+ssh://svn.code.sf.net/p/supertuxkart/code/main/trunk@11170 178a84e3-b1eb-0310-8ba1-8eac791a3b58
This commit is contained in:
@@ -949,6 +949,7 @@ KartSelectionScreen::KartSelectionScreen() : Screen("karts.stkgui")
|
||||
{
|
||||
m_removed_widget = NULL;
|
||||
m_multiplayer_message = NULL;
|
||||
m_from_overworld = false;
|
||||
} // KartSelectionScreen
|
||||
|
||||
// ----------------------------------------------------------------------------
|
||||
|
||||
@@ -264,6 +264,7 @@ void MainMenuScreen::eventCallback(Widget* widget, const std::string& name,
|
||||
{
|
||||
KartSelectionScreen* s = KartSelectionScreen::getInstance();
|
||||
s->setMultiplayer(true);
|
||||
s->setFromOverworld(false);
|
||||
StateManager::get()->pushScreen( s );
|
||||
}
|
||||
else if (selection == "options")
|
||||
|
||||
Reference in New Issue
Block a user