From af7fefee1e5744d3e68599600876347d1f69f99b Mon Sep 17 00:00:00 2001 From: Fantasmos Date: Thu, 26 Oct 2017 11:32:43 +1100 Subject: [PATCH] note errors --- src/states_screens/track_info_screen.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/states_screens/track_info_screen.cpp b/src/states_screens/track_info_screen.cpp index 55007ff47..f789e59bd 100644 --- a/src/states_screens/track_info_screen.cpp +++ b/src/states_screens/track_info_screen.cpp @@ -169,8 +169,8 @@ void TrackInfoScreen::init() if (has_AI) { m_ai_kart_spinner->setActive(true); - - int num_ai = stoi(karts_per_gamemode[race_manager->getMinorMode()]) - local_players; + int gamemode = race_manager->getMinorMode(); + int num_ai = stoi(karts_per_gamemode[gamemode]) - local_players; //TODO error caused by enums not being sequential // Avoid negative numbers (which can happen if e.g. the number of karts // in a previous race was lower than the number of players now. @@ -248,7 +248,7 @@ void TrackInfoScreen::init() //This is causing an error karts_per_gamemode[race_manager->getMinorMode()] = std::to_string(race_manager->getNumLocalPlayers()); - UserConfigParams::m_karts_per_gamemode = karts_per_gamemode; //Causes error + // UserConfigParams::m_karts_per_gamemode = karts_per_gamemode; //TODO Causes error UserConfigParams::m_num_karts = race_manager->getNumLocalPlayers(); } else if (record_available)