From 94dc746351f8549b8aac75736f59fd577e690f97 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?L=C3=A9o=20Lam?= Date: Sat, 12 May 2018 17:08:24 +0200 Subject: [PATCH] Copy Wii NAND data to user NAND in WiiRoot Dolphin doesn't use any of the WC24 files, so this can be done when actually starting emulation in WiiRoot. The benefit of moving the copy is that we don't need to handle temporary NANDs in a special way. --- Source/Core/Core/WiiRoot.cpp | 4 ++-- Source/Core/UICommon/UICommon.cpp | 3 --- 2 files changed, 2 insertions(+), 5 deletions(-) diff --git a/Source/Core/Core/WiiRoot.cpp b/Source/Core/Core/WiiRoot.cpp index 526b2e923b..5aa435c806 100644 --- a/Source/Core/Core/WiiRoot.cpp +++ b/Source/Core/Core/WiiRoot.cpp @@ -81,11 +81,11 @@ void ShutdownWiiRoot() void InitializeWiiFileSystemContents() { + File::CopyDir(File::GetSysDirectory() + WII_USER_DIR, File::GetUserPath(D_SESSION_WIIROOT_IDX)); + if (s_temp_wii_root.empty()) return; - File::CopyDir(File::GetSysDirectory() + WII_USER_DIR, s_temp_wii_root); - // Generate a SYSCONF with default settings for the temporary Wii NAND. SysConf sysconf{IOS::HLE::GetIOS()->GetFS()}; sysconf.Save(); diff --git a/Source/Core/UICommon/UICommon.cpp b/Source/Core/UICommon/UICommon.cpp index 7ac4c226fb..b4d3a8acfc 100644 --- a/Source/Core/UICommon/UICommon.cpp +++ b/Source/Core/UICommon/UICommon.cpp @@ -130,9 +130,6 @@ void SetLocale(std::string locale_name) void CreateDirectories() { - // Copy initial Wii NAND data from Sys to User. - File::CopyDir(File::GetSysDirectory() + WII_USER_DIR, File::GetUserPath(D_WIIROOT_IDX)); - File::CreateFullPath(File::GetUserPath(D_USER_IDX)); File::CreateFullPath(File::GetUserPath(D_CACHE_IDX)); File::CreateFullPath(File::GetUserPath(D_CONFIG_IDX));