2021-01-17 02:32:06 +01:00
@ echo off
setlocal
2023-03-10 02:37:08 +01:00
: : add set KeepInvalidOverride=Y to settings.bat before running
: :chdir /d "%~dp0"
pushd " %~dp0 "
cls
2021-01-17 02:32:06 +01:00
if not exist support cd ..
6.6.2 Changelog - 2021:04-06:
*Added multi-language support for analyzing syscheck.csv logs (English, German, French, Spanish & Italian).
*NAND backups are now included in syscheck updater guides when updating the HBC or Bootmii.
*Improvements to syscheck updater guide based on the version of the HBC currently installed:
-If the HBC/Bootmii needs to be updated, and IOS58 is already installed, updating the HBC is the first step.
-If the HBC/Bootmii needs to be updated, and IOS58 is not already installed, ModMii will have you update this AFTER the install WADs (or Priiloader) step in order to have the HBC reinstall to use IOS58.
-If the HBC is super old (older than v1.0.7), updating the HBC is the first step in order to gain ahbprot\no-ios-reload support, then ONLY if IOS58 was not already installed according to the syscheck the HBC is reinstalled after the install Wads (or Priiloader) step in order to have the HBC reinstall to use IOS58.
*ModMii now detects if it's missing write access to the installation folder, and only if necessary, prompts you to either change the installation directory or press any key to re-launch itself as admin. When relaunching itself, *if the standard ModMii shortcuts are detected, they will also be updated to launch ModMii as admin in the future.
*Added write permissions check for SD and USB directory settings.
*ModMii now works when installed to folders with special characters.
*Updated launchers (ModMii.exe and ModMiiSkin.exe) by person66 to support carets in installation path.
*Fixed bug where advanced download IOS patches were not being applied if the slot number was left unchanged.
*tmdedit.exe is no longer used to build d2x v10beta52 and 53alt cIOSs. One user briefly encountered problems with tmdedit that have not resurfaced, but just in case.
*Fixed bug when saving\loading MAC address for Wilbrand in ModMii Classic's saved wizard settings from a previous session.
*Restored code page to 437 as some users reported slowdowns with unicode (65001). Unicode still used but very sparingly when running the sneek installer (Windows 10 only).
*Updated cygwin1.dll to clear warnings when running ModMii's sneek game extractor or forwarder ISO creator; warnings made no difference on the output of files.
*Added note to Region Change guides on how to update Nintendo channels (e.g. News, Internet, etc.) in case existing channels don't work on the new region.
*Removed the HBC Reinstallation youtube video and gif from guides (redundant).
*Priiloader updated to v0.9.1 and updated hacks_hash for WiimmFi v4.
*Updated the version of Priiloader (and hacks) that get installed to Emulated NANDs to v0.9.1 (from v0.7 neek mod). Also added note when installing Priiloader to an EmuNAND that it is bypassed in neek2o rev 93-96.
*USB Loader GX updated to v3.0 r1272 mod v6.
*WiiFlow Lite updated to v5.4.9.
*Nintendont updated to v6.492.
*ShowMiiWads updated to v1.5 Mod; now includes 64bit version in addition to 32bit.
*If ModMii appears infected you should quarantine for 2 weeks before gaming online.
*Other minor changes.
2021-04-06 22:37:37 +02:00
set PATH = %SystemRoot% \system32;%SystemRoot% \system32\wbem;%SystemRoot% ;%homedrive% \ModMii\temp
chcp 437> nul
2021-01-17 02:32:06 +01:00
if not exist temp\DownloadQueues mkdir temp\DownloadQueues
: :build dummy files to speed up build
call Support\d2x-beta\d2x-beta.bat
: :remove setting path's with an & symbol and force default
if exist Support\settings.bat support\sfk filter -spat Support\settings.bat -!" \x26 " -write -yes> nul
if exist Support\settings.bat call Support\settings.bat
2023-03-10 02:37:08 +01:00
2021-01-17 02:32:06 +01:00
if " %Drive% " == " " set Drive = COPY_TO_SD
6.6.2 Changelog - 2021:04-06:
*Added multi-language support for analyzing syscheck.csv logs (English, German, French, Spanish & Italian).
*NAND backups are now included in syscheck updater guides when updating the HBC or Bootmii.
*Improvements to syscheck updater guide based on the version of the HBC currently installed:
-If the HBC/Bootmii needs to be updated, and IOS58 is already installed, updating the HBC is the first step.
-If the HBC/Bootmii needs to be updated, and IOS58 is not already installed, ModMii will have you update this AFTER the install WADs (or Priiloader) step in order to have the HBC reinstall to use IOS58.
-If the HBC is super old (older than v1.0.7), updating the HBC is the first step in order to gain ahbprot\no-ios-reload support, then ONLY if IOS58 was not already installed according to the syscheck the HBC is reinstalled after the install Wads (or Priiloader) step in order to have the HBC reinstall to use IOS58.
*ModMii now detects if it's missing write access to the installation folder, and only if necessary, prompts you to either change the installation directory or press any key to re-launch itself as admin. When relaunching itself, *if the standard ModMii shortcuts are detected, they will also be updated to launch ModMii as admin in the future.
*Added write permissions check for SD and USB directory settings.
*ModMii now works when installed to folders with special characters.
*Updated launchers (ModMii.exe and ModMiiSkin.exe) by person66 to support carets in installation path.
*Fixed bug where advanced download IOS patches were not being applied if the slot number was left unchanged.
*tmdedit.exe is no longer used to build d2x v10beta52 and 53alt cIOSs. One user briefly encountered problems with tmdedit that have not resurfaced, but just in case.
*Fixed bug when saving\loading MAC address for Wilbrand in ModMii Classic's saved wizard settings from a previous session.
*Restored code page to 437 as some users reported slowdowns with unicode (65001). Unicode still used but very sparingly when running the sneek installer (Windows 10 only).
*Updated cygwin1.dll to clear warnings when running ModMii's sneek game extractor or forwarder ISO creator; warnings made no difference on the output of files.
*Added note to Region Change guides on how to update Nintendo channels (e.g. News, Internet, etc.) in case existing channels don't work on the new region.
*Removed the HBC Reinstallation youtube video and gif from guides (redundant).
*Priiloader updated to v0.9.1 and updated hacks_hash for WiimmFi v4.
*Updated the version of Priiloader (and hacks) that get installed to Emulated NANDs to v0.9.1 (from v0.7 neek mod). Also added note when installing Priiloader to an EmuNAND that it is bypassed in neek2o rev 93-96.
*USB Loader GX updated to v3.0 r1272 mod v6.
*WiiFlow Lite updated to v5.4.9.
*Nintendont updated to v6.492.
*ShowMiiWads updated to v1.5 Mod; now includes 64bit version in addition to 32bit.
*If ModMii appears infected you should quarantine for 2 weeks before gaming online.
*Other minor changes.
2021-04-06 22:37:37 +02:00
: :check if drive folder exists--if second char is ":" check if drive exists
if /i " %DRIVE% " EQU " %cd% \COPY_TO_SD " set DRIVE = COPY_TO_SD
if /i " %DRIVE:~1,1% " NEQ " : " goto : skipcheck
if exist " %DRIVE:~0,2% " ( goto : skipcheck ) else ( set DRIVE = COPY_TO_SD)
: skipcheck
2021-01-17 02:32:06 +01:00
if not exist " %Drive% \WAD " mkdir " %Drive% \WAD "
2023-03-10 02:37:08 +01:00
echo dummy> " %DRIVE% \WAD\cIOS248[38]-d2x-v %d2x-beta-rev% .wad "
2021-01-17 02:32:06 +01:00
echo dummy> " %DRIVE% \WAD\cIOS249[37]-d2x-v %d2x-beta-rev% .wad "
echo dummy> " %DRIVE% \WAD\cIOS250[37]-d2x-v %d2x-beta-rev% .wad "
echo dummy> " %DRIVE% \WAD\cIOS249[38]-d2x-v %d2x-beta-rev% .wad "
echo dummy> " %DRIVE% \WAD\cIOS250[38]-d2x-v %d2x-beta-rev% .wad "
echo dummy> " %DRIVE% \WAD\cIOS249[53]-d2x-v %d2x-beta-rev% .wad "
echo dummy> " %DRIVE% \WAD\cIOS250[53]-d2x-v %d2x-beta-rev% .wad "
echo dummy> " %DRIVE% \WAD\cIOS249[55]-d2x-v %d2x-beta-rev% .wad "
echo dummy> " %DRIVE% \WAD\cIOS250[55]-d2x-v %d2x-beta-rev% .wad "
echo dummy> " %DRIVE% \WAD\cIOS249[56]-d2x-v %d2x-beta-rev% .wad "
echo dummy> " %DRIVE% \WAD\cIOS250[56]-d2x-v %d2x-beta-rev% .wad "
echo dummy> " %DRIVE% \WAD\cIOS249[57]-d2x-v %d2x-beta-rev% .wad "
echo dummy> " %DRIVE% \WAD\cIOS250[57]-d2x-v %d2x-beta-rev% .wad "
echo dummy> " %DRIVE% \WAD\cIOS249[58]-d2x-v %d2x-beta-rev% .wad "
echo dummy> " %DRIVE% \WAD\cIOS250[58]-d2x-v %d2x-beta-rev% .wad "
echo dummy> " %DRIVE% \WAD\cIOS249[60]-d2x-v %d2x-beta-rev% .wad "
echo dummy> " %DRIVE% \WAD\cIOS250[60]-d2x-v %d2x-beta-rev% .wad "
echo dummy> " %DRIVE% \WAD\cIOS249[70]-d2x-v %d2x-beta-rev% .wad "
echo dummy> " %DRIVE% \WAD\cIOS250[70]-d2x-v %d2x-beta-rev% .wad "
echo dummy> " %DRIVE% \WAD\cIOS249[80]-d2x-v %d2x-beta-rev% .wad "
echo dummy> " %DRIVE% \WAD\cIOS250[80]-d2x-v %d2x-beta-rev% .wad "
2023-03-10 02:37:08 +01:00
echo dummy> " %DRIVE% \WAD\cIOS251[58]-d2x-v %d2x-beta-rev% .wad "
2021-01-17 02:32:06 +01:00
: :build d2xAll queue
echo set AdvNumber=0 > temp\DownloadQueues\d2xAll.bat
echo if /i '?GetAdvNumberOnly?' EQU 'Y' goto:endofqueue>> temp\DownloadQueues\d2xAll.bat
echo Set ROOTSAVE=off>> temp\DownloadQueues\d2xAll.bat
echo Set Option1=off>> temp\DownloadQueues\d2xAll.bat
2023-03-10 02:37:08 +01:00
echo Set cIOS248[38]-d2x-v10-beta52=*>> temp\DownloadQueues\d2xAll.bat
echo Set cIOS249[37]-d2x-v10-beta52=*>> temp\DownloadQueues\d2xAll.bat
echo Set cIOS249[38]-d2x-v10-beta52=*>> temp\DownloadQueues\d2xAll.bat
echo Set cIOS249[56]-d2x-v10-beta52=*>> temp\DownloadQueues\d2xAll.bat
echo Set cIOS249[53]-d2x-v10-beta52=*>> temp\DownloadQueues\d2xAll.bat
echo Set cIOS249[55]-d2x-v10-beta52=*>> temp\DownloadQueues\d2xAll.bat
echo Set cIOS249[57]-d2x-v10-beta52=*>> temp\DownloadQueues\d2xAll.bat
echo Set cIOS249[58]-d2x-v10-beta52=*>> temp\DownloadQueues\d2xAll.bat
echo Set cIOS249[60]-d2x-v10-beta52=*>> temp\DownloadQueues\d2xAll.bat
echo Set cIOS249[70]-d2x-v10-beta52=*>> temp\DownloadQueues\d2xAll.bat
echo Set cIOS249[80]-d2x-v10-beta52=*>> temp\DownloadQueues\d2xAll.bat
echo Set cIOS250[37]-d2x-v10-beta52=*>> temp\DownloadQueues\d2xAll.bat
echo Set cIOS250[38]-d2x-v10-beta52=*>> temp\DownloadQueues\d2xAll.bat
echo Set cIOS250[53]-d2x-v10-beta52=*>> temp\DownloadQueues\d2xAll.bat
echo Set cIOS250[55]-d2x-v10-beta52=*>> temp\DownloadQueues\d2xAll.bat
echo Set cIOS250[56]-d2x-v10-beta52=*>> temp\DownloadQueues\d2xAll.bat
echo Set cIOS250[57]-d2x-v10-beta52=*>> temp\DownloadQueues\d2xAll.bat
echo Set cIOS250[58]-d2x-v10-beta52=*>> temp\DownloadQueues\d2xAll.bat
echo Set cIOS250[60]-d2x-v10-beta52=*>> temp\DownloadQueues\d2xAll.bat
echo Set cIOS250[70]-d2x-v10-beta52=*>> temp\DownloadQueues\d2xAll.bat
echo Set cIOS250[80]-d2x-v10-beta52=*>> temp\DownloadQueues\d2xAll.bat
echo Set cIOS251[58]-d2x-v10-beta52=*>> temp\DownloadQueues\d2xAll.bat
2021-01-17 02:32:06 +01:00
echo :endofqueue>> temp\DownloadQueues\d2xAll.bat
support\sfk filter -spat temp\DownloadQueues\d2xAll.bat -rep _\x27_\x22_ -rep _\x3f_\x25_ -rep _" AdvNumber=0 " _" AdvNumber=0 " _ -write -yes> nul
echo d2x cIOS beta MD5 Updater
echo -------------------------
echo .
echo Building d2x-beta cIOSs...
echo .
echo The 1st time ModMii runs the cIOSs will be invalid and open a text window
echo The 2nd time ModMii runs the cIOSs should be valid and not open a text window
echo .
2023-03-10 02:37:08 +01:00
echo If you have issues, make sure set KeepInvalidOverride=Y has been manually added to settings.bat before running
echo .
2021-01-17 02:32:06 +01:00
: :echo @echo off>d2xAll-Downloader.bat
: :echo setlocal>>d2xAll-Downloader.bat
: :echo call support\ModMii.bat L d2xALL>>d2xAll-Downloader.bat
: :start /wait d2xAll-Downloader.bat
ModMii.exe L d2xALL
: :del d2xAll-Downloader.bat>nul
if exist Support\settings.bat call Support\settings.bat
if " %Drive% " == " " set Drive = COPY_TO_SD
if exist d2xALL.md5 del d2xALL.md5> nul
support\fvc -c -a MD5 -r " %DRIVE% " \WAD\*.wad>> d2xALL.md5
if not exist Support\d2x-beta\d2x-beta.bat ( echo Error: Missing Support\d2x-beta\d2x-beta.bat) & ( @ ping 127.0.0.1 -n 2 -w 1000> nul) & ( exit )
echo Updating d2x MD5s...
call Support\d2x-beta\d2x-beta.bat
copy /y Support\d2x-beta\d2x-beta.bat Support\d2x-beta\d2x-beta.bak> nul
set number = 0
: top
SET /a number =% number %+ 1
2023-03-10 02:37:08 +01:00
if /i " %number% " EQU " 1 " set cios = cIOS248[38]
if /i " %number% " EQU " 2 " set cios = cIOS249[37]
if /i " %number% " EQU " 3 " set cios = cIOS250[37]
if /i " %number% " EQU " 4 " set cios = cIOS249[38]
if /i " %number% " EQU " 5 " set cios = cIOS250[38]
if /i " %number% " EQU " 6 " set cios = cIOS249[53]
if /i " %number% " EQU " 7 " set cios = cIOS250[53]
if /i " %number% " EQU " 8 " set cios = cIOS249[55]
if /i " %number% " EQU " 9 " set cios = cIOS250[55]
if /i " %number% " EQU " 10 " set cios = cIOS249[56]
if /i " %number% " EQU " 11 " set cios = cIOS250[56]
if /i " %number% " EQU " 12 " set cios = cIOS249[57]
if /i " %number% " EQU " 13 " set cios = cIOS250[57]
if /i " %number% " EQU " 14 " set cios = cIOS249[58]
if /i " %number% " EQU " 15 " set cios = cIOS250[58]
if /i " %number% " EQU " 16 " set cios = cIOS249[60]
if /i " %number% " EQU " 17 " set cios = cIOS250[60]
if /i " %number% " EQU " 18 " set cios = cIOS249[70]
if /i " %number% " EQU " 19 " set cios = cIOS250[70]
if /i " %number% " EQU " 20 " set cios = cIOS249[80]
if /i " %number% " EQU " 21 " set cios = cIOS250[80]
if /i " %number% " EQU " 22 " set cios = cIOS251[58]
2021-01-17 02:32:06 +01:00
copy /y d2xALL.md5 temp\d2xALL.txt> nul
support\sfk filter -spat temp\d2xALL.txt -+" %cios% -d2x-v %d2x-beta-rev% .wad " -rep _" * " __ -write -yes> nul
set /p ciosmd5 = < temp\d2xALL.txt
: :echo %cios%-d2x-v%d2x-beta-rev% MD5 = %ciosmd5%
support\sfk filter -spat Support\d2x-beta\d2x-beta.bat -rep _" %cios% -d2x-v\x22 set md5= " *_" %cios% -d2x-v\x22 set md5= %ciosmd5% " _ -write -yes> nul
: :delete wad: it will be reconstructed and confirmed later
del " %DRIVE% \WAD\ %cios% -d2x-v %d2x-beta-rev% .wad " > nul
2023-03-10 02:37:08 +01:00
if " %number% " NEQ " 22 " goto : top
2021-01-17 02:32:06 +01:00
echo .
echo d2x-beta.bat Updated
echo .
del temp\d2xALL.txt> nul
del d2xALL.md5> nul
if exist " Support\More-cIOSs\d2x-v %d2x-beta-rev% " rd /s /q " Support\More-cIOSs\d2x-v %d2x-beta-rev% "
mkdir " Support\More-cIOSs\d2x-v %d2x-beta-rev% "
copy /y Support\d2x-beta\* " Support\More-cIOSs\d2x-v %d2x-beta-rev% \ " > nul
del " Support\More-cIOSs\d2x-v %d2x-beta-rev% \d2x-beta.bak " > nul
2023-03-10 02:37:08 +01:00
if exist " d2x-v %d2x-beta-rev% .7z " del " d2x-v %d2x-beta-rev% .7z " > nul
2021-01-17 02:32:06 +01:00
cd Support\More-cIOSs
2023-03-10 02:37:08 +01:00
..\7za a -t7z " ..\..\d2x-v %d2x-beta-rev% .7z " " d2x-v %d2x-beta-rev% \*.bat "
..\7za a -t7z " ..\..\d2x-v %d2x-beta-rev% .7z " " d2x-v %d2x-beta-rev% \*.app "
2021-01-17 02:32:06 +01:00
cd " d2x-v %d2x-beta-rev% "
2023-03-10 02:37:08 +01:00
if exist " *.xml " ..\..\7za a -t7z " ..\..\..\d2x-v %d2x-beta-rev% .7z " " *.xml "
if exist " *.txt " ..\..\7za a -t7z " ..\..\..\d2x-v %d2x-beta-rev% .7z " " *.txt "
2021-01-17 02:32:06 +01:00
cd ..\..\..
echo .
2023-03-10 02:37:08 +01:00
echo ModMii about to verify...
2021-01-17 02:32:06 +01:00
echo .
: :call support\ModMii.bat L d2xALL
: :start /wait d2xAll-Downloader.bat
: :del d2xAll-Downloader.bat>nul
ModMii.exe L d2xALL
2023-03-10 02:37:08 +01:00
findStr /I /C:" 22 file(s) downloaded succcessfully " temp\ModMii_CMD_LINE_Log.txt > nul
IF not ERRORLEVEL 1 ( echo SUCCESS! To finalize see note on how to MANUALLY update MD5 for cIOS251-38 in d2x-beta.bat for legacy support of v6.6.0-6.6.3, or don't it's not a big deal) & ( pause ) & ( exit )
2021-01-17 02:32:06 +01:00
echo .
2023-03-10 02:37:08 +01:00
echo Something went wrong...
2021-01-17 02:32:06 +01:00
pause