diff --git a/src/states_screens/dialogs/addons_loading.cpp b/src/states_screens/dialogs/addons_loading.cpp index 9d868559f..1b429d0f6 100644 --- a/src/states_screens/dialogs/addons_loading.cpp +++ b/src/states_screens/dialogs/addons_loading.cpp @@ -30,6 +30,8 @@ #include "io/file_manager.hpp" #include "online/request_manager.hpp" #include "online/xml_request.hpp" +#include "race/grand_prix_manager.hpp" +#include "replay/replay_play.hpp" #include "states_screens/addons_screen.hpp" #include "states_screens/dialogs/message_dialog.hpp" #include "states_screens/dialogs/vote_dialog.hpp" @@ -397,6 +399,11 @@ void AddonsLoading::doInstall() } track_manager->loadTrackList(); + // Update the replay file list to use latest track pointer + ReplayPlay::get()->loadAllReplayFile(); + delete grand_prix_manager; + grand_prix_manager = new GrandPrixManager(); + grand_prix_manager->checkConsistency(); #endif } // doInstall @@ -434,5 +441,10 @@ void AddonsLoading::doUninstall() AddonsScreen::getInstance()->loadList(); dismiss(); } + // Update the replay file list to use latest track pointer + ReplayPlay::get()->loadAllReplayFile(); + delete grand_prix_manager; + grand_prix_manager = new GrandPrixManager(); + grand_prix_manager->checkConsistency(); #endif } // doUninstall diff --git a/src/utils/extract_mobile_assets.cpp b/src/utils/extract_mobile_assets.cpp index 613eae632..2386ab36d 100644 --- a/src/utils/extract_mobile_assets.cpp +++ b/src/utils/extract_mobile_assets.cpp @@ -77,6 +77,8 @@ void ExtractMobileAssets::reinit() file_manager->reinitAfterDownloadAssets(); irr_driver->sameRestart(); track_manager->loadTrackList(); + // Update the replay file list to use latest track pointer + ReplayPlay::get()->loadAllReplayFile(); delete grand_prix_manager; grand_prix_manager = new GrandPrixManager();