├── .gitattributes ├── .gitignore ├── Change.log ├── README.md ├── createExecutables.bat ├── createShortcuts.bat ├── doc ├── Wii U Error Codes.rtf ├── cemuInterfacesHistory.txt ├── contributors.txt ├── executables.txt ├── goal.txt ├── graphicPacksHandling.txt ├── howItWorks.txt ├── mlc01data.txt ├── syncWii-U.txt ├── updateGamesGraphicPacks.png ├── updateInstallUse.txt └── userSavesAndSlots.txt ├── resources ├── BRC_Unicode_64 │ ├── BRC64.exe │ └── pcre.dll ├── Bat_To_Exe_Converter.exe ├── BatchFw.png ├── GFX_Packs.rar ├── JNUST │ ├── JNUSTool.jar │ ├── JNUSTool.txt │ ├── WudCompress.exe │ └── wud2app.exe ├── Quick_Any2Ico.exe ├── Quick_Any2Ico.txt ├── Rar.exe ├── V2_GFX_Packs.rar ├── V4_GFX_Packs.rar ├── WiiU-Titles-Library.csv ├── WiiuSDcard.rar ├── cemuhook_1116_0564.rar ├── cemuhook_1159_0573.rar ├── cemuhook_1251_0574.rar ├── cmdow.exe ├── convert.exe ├── du.exe ├── fat32format.exe ├── fnr.exe ├── gamesIcons │ └── Readme.txt ├── getShaderCacheName │ ├── getShaderCacheName.exe │ └── main.c ├── icons │ ├── BatchFw.ico │ ├── BatchFw.png │ ├── Cemu.ico │ ├── DS4Windows.ico │ ├── ImportSave.ico │ ├── ImportSaves.ico │ ├── Wii-U Error Codes.ico │ ├── WiiU-user.ico │ ├── WiiU-user.png │ ├── WiiU.png │ ├── WiiUfwuOff.ico │ ├── WiiUfwuOff.png │ ├── WiiUfwuOn.ico │ ├── WiiUfwuOn.png │ ├── WinSCP.ico │ ├── Wud2Rpx.ico │ ├── Wud2Wup.ico │ ├── Wud2Wux.ico │ ├── WudxWup.ico │ ├── Wup2Rpx.ico │ ├── Wux2Rpx.ico │ ├── Wux2Wud.ico │ ├── backupAllInGameSaves.ico │ ├── buildExtraGraphicPacks.ico │ ├── cemu.png │ ├── compress.ico │ ├── compress.png │ ├── convertIconsForAllGames.ico │ ├── copyMlc01DataForAllGames.ico │ ├── createExecutables.ico │ ├── createGameGraphicPacks.ico │ ├── createShortcuts.ico │ ├── delete.ico │ ├── deleteAllInGameSaves.ico │ ├── deleteAllInGameSavesBackup.ico │ ├── deleteAllMySettings.ico │ ├── deleteGamesShortcuts.ico │ ├── deleteGamesShortcuts.png │ ├── deleteMyGLCacheBackup.ico │ ├── deleteMyGpuCache.ico │ ├── disableProgressBar.ico │ ├── displayGamesStats.ico │ ├── displayGamesStats.png │ ├── download.ico │ ├── downloadGames.ico │ ├── enableProgressBar.ico │ ├── exploreOpenGLCacheSaves.ico │ ├── exportAllToCemu.ico │ ├── exportSave.ico │ ├── exportSave.png │ ├── exportUserGamesStatsToCemu.ico │ ├── fixBrokenShortcuts.ico │ ├── fixBrokenShortcuts.png │ ├── forceGraphicPackUpdate.ico │ ├── getMyShaderCachesSize.ico │ ├── getTitleDataFromLibrary.ico │ ├── importGames.ico │ ├── importModsForAllGames.ico │ ├── importSave.ico │ ├── importSave.png │ ├── importTransferableCache.ico │ ├── kill.ico │ ├── kill.png │ ├── moveMlc01DataForAllGames.ico │ ├── noIconFound.ico │ ├── notepad.ico │ ├── online.ico │ ├── online.jpg │ ├── restoreBfwDefaultSettings.ico │ ├── restoreMlc01DataForAllGames.ico │ ├── restoreTransShadersForAllGames.ico │ ├── restoreUserSavesOfAllGames.ico │ ├── save.jpg │ ├── saveSlots.ico │ ├── scanResults.ico │ ├── scanResults.png │ ├── sdcard.ico │ ├── sdcard.png │ ├── settings.png │ ├── setup.ico │ ├── syncGamesFolder.ico │ ├── syncGamesFolder.png │ ├── uninstall.ico │ ├── updateGames.ico │ ├── updateGraphicPacksFolder.ico │ ├── upload.ico │ ├── wii-u.ico │ ├── wii-u.png │ ├── wipe.ico │ └── wipe.png ├── ps1 │ ├── getLatestBFW.ps1 │ ├── getLatestGP.ps1 │ ├── updateBFW.ps1 │ └── updateGP.ps1 ├── sharedFonts.rar ├── vbs │ ├── BrowseFileDialog.vbs │ ├── BrowseFolderDialog.vbs │ ├── MessageBox.vbs │ ├── Start.vbs │ ├── StartHidden.vbs │ ├── StartHiddenCmd.vbs │ ├── StartHiddenWait.vbs │ ├── StartMaximized.vbs │ ├── StartMaximizedWait.vbs │ ├── StartMinimized.vbs │ ├── StartMinimizedWait.vbs │ └── StartWait.vbs ├── winSCP │ ├── WinSCP.com │ ├── WinSCP.exe │ └── WinSCP.ini-tmpl ├── xml.exe └── xml.txt ├── setup.bat ├── tools ├── backupAllInGameSaves.bat ├── backupInGameSaves.bat ├── buildExtraGraphicPacks.bat ├── checkGameContentAvailability.bat ├── checkGameUpdateAvailability.bat ├── completeLastGraphicPacks.bat ├── completeV2GraphicPacks.bat ├── completeV4GraphicPacks.bat ├── compressAndUninstall.bat ├── convertIconsForAllGames.bat ├── convertWiiuFiles.bat ├── copyMlc01DataForAllGames.bat ├── createCapGraphicPacks.bat ├── createExecutables.bat ├── createExtraGraphicPacks.bat ├── createGameGraphicPacks.bat ├── createLastGraphicPacks.bat ├── createOneV2GraphicPack.bat ├── createShortcuts.bat ├── createV2GraphicPacks.bat ├── createV4GraphicPacks.bat ├── createWiiuSDcard.bat ├── deleteAllInGameSavesBackup.bat ├── deleteAllMySettings.bat ├── deleteBatchFwGraphicPacks.bat ├── deleteMyGpuCache.bat ├── detectAndRenameInvalidPath.bat ├── displayGamesStats.bat ├── displayProgressBar.bat ├── downloadGames.bat ├── downloadTitleId.bat ├── dumpGamesFromWiiu.bat ├── exportAllToCemu.bat ├── exportSavesToWiiu.bat ├── exportUserGamesStatsToCemu.bat ├── fixBatFiles.bat ├── fixBrokenShortcuts.bat ├── forceGraphicPackUpdate.bat ├── ftpReplaceFolders.bat ├── ftpSetWiiuFirmwareUpdateMode.bat ├── ftpSyncFolders.bat ├── getDllOrExeVersion.bat ├── getMyShaderCachesSize.bat ├── getTitleDataFromLibrary.bat ├── getWiiuOnlineFiles.bat ├── importGames.bat ├── importModsForAllGames.bat ├── importSaves.bat ├── importTransferableCache.bat ├── importWiiuSaves.bat ├── initProgressBar.bat ├── injectGamesToWiiu.bat ├── instanciateResX2gp.bat ├── killBatchFw.bat ├── launchGame.bat ├── launchThirdPartySoftware.bat ├── monitorBatchFw.bat ├── moveMlc01DataForAllGames.bat ├── multiply.bat ├── progressBar.bat ├── reportCompatibility.bat ├── restoreBfwDefaultSettings.bat ├── restoreMlc01DataForAllGames.bat ├── restoreTransShadersForAllGames.bat ├── restoreUserSavesOfAllGames.bat ├── scanWiiU.bat ├── setExtraSavesSlots.bat ├── setWiiuAccountToUsers.bat ├── setup.bat ├── stopThirdPartySoftware.bat ├── syncGamesFolder.bat ├── uninstall.bat ├── updateBatchFw.bat ├── updateGameStats.bat ├── updateGames.bat ├── updateGamesGraphicPacks.bat ├── updateGraphicPacksFolder.bat ├── validateExtraGraphicPacksCreation.bat ├── wipeTracesOnHost.bat └── wizardFirstSaving.bat └── uninstall.bat /.gitattributes: -------------------------------------------------------------------------------- 1 | # Auto detect text files and perform LF normalization 2 | * text=auto 3 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | /logs/ 2 | -------------------------------------------------------------------------------- /Change.log: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/Change.log -------------------------------------------------------------------------------- /doc/cemuInterfacesHistory.txt: -------------------------------------------------------------------------------- 1 | ========================================================= 2 | CEMU HISTORY : 3 | ========================================================= 4 | 5 | CEMU 1.8 Broke shader cache compatibility -> If you try to import a shader cache on earlier 6 | version, it will be erase/reset by CEMU; 7 | CEMU 1.10 Added -mlc argument to customize path for mlc01 directory -> In earlier version, all 8 | games' data were mixed in mlc01 subfolder in CEMU; 9 | CEMU 1.11 Modified saving process and location: broken compatibility on saves -> Use Cemu 1.11 to 10 | import/format your saves from previous versions; 11 | CEMU 1.12.0 Added games list; 12 | CEMU 1.12.1 Added disable precompiled shader cache option (UI settings & in game profiles); 13 | CEMU 1.13 Added -mlc settings in UI to customize path for mlc01 directory; 14 | CEMU 1.14 Shader reworked and introduced V3 graphic packs; 15 | CEMU 1.15.1 Support for game's mods and protection of the GLCache under shaderCahce/driver/nvidia; 16 | CEMU 1.15.6 Save controler profile used in the game's profile when using the UI (right click on the game in the list); 17 | CEMU 1.15.10 Add auto-updater; 18 | CEMU 1.15.15 User game's profiles (not overwritted when updating); 19 | CEMU 1.15.19 Accounts handling (multi users) 20 | CEMU 1.16 Vulkan API 21 | CEMU 1.17.2 Enhance multi-core recompiler compatibility (more games support it) 22 | CEMU 1.19.0 Vulkan async compilation 23 | CEMU 1.21.0 Introduced V6 packs 24 | CEMU 1.22.0 New multi-core modes : Auto / Single-core, Multi-core 25 | 26 | Before 1.11, saves were in mlc01/emulatorSave/ShaderCacheId and updates and DLC were applied by overwriting files. 27 | After 1.11, they are stored in mlc01/usr/save/titleId[0:7]/titleId[8:15]/* (where titleId is the 16 characters id 28 | of your game (cf http://wiiubrew.org/wiki/Title_database )), 29 | 30 | - updates are in mlc01/usr/title/titleId[0:7]/titleId[8:15] 31 | - and DLC are in mlc01/usr/title/titleId[0:7]/titleId[8:15]/aoc 32 | 33 | Recommended versions for BatchFw are >=1.11 (to avoid down side save format conversion issues). 34 | Anyways, if you want to use a version earlier than 1.11, you'd better have a specific Cemu install for those games. 35 | 36 | About CemuHook : 37 | --------------------- 38 | 39 | Since CemuHook 0.5.6.0 for 1.8.1-1.11.3, appears a new option in Debug menu : 40 | - Precompiled shader cache On/Off, in case you want to use only your GLCache (GPU OpenGL cache). 41 | 42 | On newer versions (>=1.15), the GLCache is not protected in CEMU's folder under shaderCahce/driver/nvidia 43 | 44 | 45 | -------------------------------------------------------------------------------- /doc/contributors.txt: -------------------------------------------------------------------------------- 1 | ========================================================= 2 | Contributors : 3 | ========================================================= 4 | 5 | - Laf111 (u/Laf111) 6 | - Nicklaj (u/Themastersimo) -------------------------------------------------------------------------------- /doc/executables.txt: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/doc/executables.txt -------------------------------------------------------------------------------- /doc/goal.txt: -------------------------------------------------------------------------------- 1 | ========================================================= 2 | GOAL : 3 | ========================================================= 4 | 5 | The main purpose of BatchFW is: 6 | 7 | Switch from game to game and automatically have all your data saved or restored on a given version of the CEMU emulator; 8 | 9 | Switch freely from a version of CEMU to another for a given game, and play with the same data you had on the first one. 10 | You can also register multiple versions of the emulator; 11 | 12 | All by creating shortcuts (or executables) on your desktop - or a folder of your choice. 13 | 14 | With BatchFw there's no need to bother about saves, caches, controller profiles, CEMU or CemuHook settings and precompiled cache 15 | ignoring if you're an NVidia user - since you won't need to build a shader cache for each version. 16 | 17 | The mlc01 path is in the game folder so 18 | 19 | you can backup a whole game by compressing its folder (saves, updates, DLCs, controller profiles, settings... are ALL included); 20 | 21 | your games library becomes portable: you can put it on an external drive and play on differents hosts (settings are stored by 22 | host and you only have to manage the shortcuts you created for each Cemu install on each host); 23 | 24 | Automatic graphics pack creation: you don't need to wait for the release of graphics packs for a yet not supported game to play at a 25 | resolution other than the native one (tested successfully on dozens of games) since BatchFW will try to create them automatically. 26 | And when an official pack for the game comes out BatchFW will automatically replace the created one. 27 | 28 | FTP transferts with your Wii-U (optional) : BatchFw use WinScp for FTP transferts (WinScp.com + an ini file template) 29 | The first time you need to access to your Wii-U, you'll have to enter the IP and the port of the Wii-U and an ini file is created. 30 | If you're using a static IP adress policy on your local network, no need to create a another configuration. 31 | You'll be able to use the first one you created. 32 | Note that if you want to run _BatchFw_Install\resources\winScp\winScp.exe (WinwScp UI) it will also use this ini file. 33 | You'll only have to start/stop the ftpiiu server on your Wii-U and launch the provided scripts 34 | 35 | Other features: 36 | 37 | Handle muti users saves (per windows's profile); 38 | 39 | GLCache backup/restore per game (AMD, NVIDIA); 40 | 41 | Automatic GLCache cleanup when updating display drivers; 42 | 43 | Secure CEMU threads by using a lock file (Though you won't be able to open multiple instances at once); 44 | 45 | Your own games compatibility datase per host you use (BatchFW logs silently the first version of CEMU that manages to run a 46 | game on this host); 47 | 48 | Your own CEMU X.Y.Z games compatibility list per host: compatibility per version and per host of all your games (last column in 49 | the csv file = code you have to enter @ http://compat.cemu.info/ to report your feedback for a game and it is filled automatically 50 | with your specs and the settings used); 51 | 52 | Easy game profile configuration per version (using shortcuts); 53 | 54 | Side by side game profile comparison; 55 | 56 | Double automatic backup of your transferable cache and saves for each games to avoid their corruption that can occur on CEMU crash; 57 | 58 | Automatic import of external transferable cache (you don't need to rename it with the right shaderCacheId of your game's region) to 59 | track broken shaderCacheId (as it happened with CEMU 1.8) and not only... 60 | 61 | ect... 62 | 63 | 64 | BatchFW does not need Adminstrator rights. 65 | 66 | All batch source code is in delayed expansion mode and uses your system charset to check/handle the minimum of unsupported characters in paths. 67 | 68 | Code is well commented and is read only. If you edit source code, use a text editor that doesn't change ANSI files format to UTF8! 69 | 70 | 71 | Feel free to modify it or enhance it but share it if you do. 72 | 73 | 74 | -------------------------------------------------------------------------------- /doc/graphicPacksHandling.txt: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/doc/graphicPacksHandling.txt -------------------------------------------------------------------------------- /doc/howItWorks.txt: -------------------------------------------------------------------------------- 1 | ========================================================= 2 | HOW IT WORKS : 3 | ========================================================= 4 | 5 | When creating shortcuts for a CEMU's version : 6 | 7 | - if a mlc01 subfolder does not exist in game's folder, batchFw will create one. 8 | - controller profiles are copied in CEMU's subfolder 9 | 10 | The first time you launch a game for a given CEMU's version, you 'll have to follow a wizard that help you to collect 11 | your settings for this game : 12 | 13 | - if a meta\meta.xml is missing, batchFw can creates one for you 14 | - if no graphic packs is found for this game, create ones for you (V2 and V3 graphic packs). 15 | - get game's data from an internal wii-u title database and complete them with game's update version and DLC 16 | presence before saving them in a text file under game's folder 17 | - if a profile file for this game is missing in CEMU, you will create one and save a copy in a 18 | _BatchFW_Missing_Profiles folder in order to share it with the others versions of CEMU 19 | - batchFw can display the example.ini of this version to helps you to fill the game's profile file with the 20 | supported directives 21 | - you can also choose to browse to another CEMU's install folder to compare game's profiles of this game side by side. 22 | - batchFw will display the current CEMU and CemuHook settings detected 23 | - launch CEMU UI a first time to ask you to select you graphic packs, at least all controller profiles for each 24 | players to this game 25 | - settings are saved under the game's folder for the current host under GAME_FOLDER\Cemu\settings\HOSTNAME\CEMU_VERSION\ 26 | 27 | 28 | After this wizard completed, all actions are done silently. 29 | When launching a game (using its shortcut or an executable), launchGame.bat script will : 30 | 31 | - check if an graphic pack update is available 32 | - if enabled, complete/create graphic packs for this game 33 | - copy saved settings to CEMU_FOLDER including only the graphic packs of this game 34 | - load game's saves for current user 35 | - creates a 2 levels backup of game's saves 36 | - provide V2 and V3 graphic packs for this game (using links) 37 | - copy transferable shader cache to CEMU install 38 | - creates a 2 level backup of transferable shader cache 39 | - retore OpenGL Cache fot this game in the GLCache working directory 40 | - create a lock file in CEMU_FOLDER, launch CEMU with a high priority 41 | - when closing CEMU : remove lock file and analyse return code to initialize CEMU_STATUS for the game and this 42 | CEMU's version 43 | - if CEMU's return code equal 0, search in compatibility report ot the current host if a row already exist for this 44 | game, creates a new one otherwise 45 | - else, open CEMU's log file 46 | - search in CEMU's version report for current rig (host) if a row already exist, create a new one otherwise 47 | - save settings under game's folder for the current hosts 48 | - restore initial CEMU's graphicPacks subfolder 49 | - save games's saves for the current user. 50 | - save the transferable cache. 51 | - analyse OpenGL Cache Id, detects display driver update, remove obsolete cache and backup the new. 52 | If an issue occurs, batchFw will open its log file. 53 | 54 | 55 | Compatibility reports are available throught shorcuts created in Wii-U Games\CEMU\Games Compatibility Reports. 56 | There are saved on your disk, in your games folder under a _BatchFW_Games_Compatibility_Reports subfolder. 57 | 58 | BatchFW does not backup game's profiles. Those files are specific to each version of CEMU. 59 | 60 | Settings now overrided with the game's profile are saved in the settings.bin on earlier versions. 61 | 62 | 63 | BatchFW creates logs under_BatchFW_install\logs for your games library and every hosts. 64 | Do not delete this log, it also contain your settings 65 | 66 | With using the tools provided to copy/move mlc01 folder's data for all your games in theirs respectives folders, with 67 | versions of CEMU newer than 1.11 your CEMU folder will finally contains only its precompiled cache shader (host dependant). 68 | All game's data (saves, updates, DLC, settings and transferable cache) are in the game's folder. 69 | 70 | Your controller profiles are saved under a _BatchFW_Controller_Profiles\USERDOMAIN (USERDOMAIN=host name) and 71 | delivered to each version of CEMU. 72 | 73 | 74 | -------------------------------------------------------------------------------- /doc/mlc01data.txt: -------------------------------------------------------------------------------- 1 | ========================================================= 2 | MIGRATE MLC01 DATA : 3 | ========================================================= 4 | 5 | BatchFw ties your game's mlc01 data to the game's folder. 6 | 7 | - to easily switch between versions of CEMU by having them share: 8 | * saves, 9 | * updates, 10 | * dlcs, 11 | by using the -mlc argument; 12 | - to make your loadiines games library portable (gather all game's data in its mlc01 subfolder); 13 | - to avoid having all data for all your games mixed in the CEMU's folder and prevent from leaving USELESS data 14 | when uninstalling a game; 15 | 16 | Shortcuts created will use -mlc option pointing to mlc01 game's subfolder (your initial mlc01 folder in your 17 | Cemu's folder will be untouched) 18 | So you can safely choose the first time to copy your mlc01 CEMU's subfolder (and remove it later if you 19 | keep BatchFW installed); 20 | 21 | But before copying or moving, check your left space on your drives. If you have enough space, we recommend to 22 | copy the mlc01 folder instead of moving it. 23 | 24 | If you want to uninstall BatchFW and have progressed in some games, choose to revert mlc01 from games's folders 25 | to your CEMU folder in order to keep your last saves created during BatchFW's trial. 26 | You should also think to choose to revert transferable cache. 27 | 28 | 29 | -------------------------------------------------------------------------------- /doc/syncWii-U.txt: -------------------------------------------------------------------------------- 1 | ========================================================= 2 | WII-U transferts : 3 | ========================================================= 4 | 5 | BatchFw use WinScp for FTP transferts (WinScp.com + an ini file template) 6 | The first time you need to access to your Wii-U, you'll have to enter the IP fo the Wii-U and the port 7 | An ini file is created. 8 | 9 | If you're using a static IP adress policy on your local network, no need to create a another configuration. 10 | You'll be able to use the first one you created. 11 | Note that if you want to run _BatchFw_Install\resources\winScp\winScp.exe (WinwScp UI) it will also use 12 | this ini file. 13 | 14 | I'll only have to start/stop the ftpiiu server on your Wii-U and launch the scripts. 15 | 16 | --------------------------------------------------------- 17 | Create a SDCard for Wii-U 18 | --------------------------------------------------------- 19 | BatchFw can prepare a SDcard for your Wii-U (format the device in FAT32 with 64K clusters size using fat32format.exe 20 | then install the needed app : HBL, DDD, NandDumper, CBHC, Loadiine_GX2, MOCHA, SigPatcher2SysMenu, WUP_installer_GX2, 21 | SaveMii_MOD, FTPiiU for MOCHA and CBHC). 22 | If you're running a CBHC CFW use FTP everywhere FOR CBHC. 23 | Otherwise launch MOCHA then FTP everywhere FOR MOCHA. 24 | 25 | --------------------------------------------------------- 26 | Scan my Wii-U : _BatchFw_WiiU\Scans\YYYY-MM-DD_HH-MM-SS 27 | --------------------------------------------------------- 28 | This feature allows you to take snasphot of your wii-U to list games, updates, DLC and saves installed on storage_mlc 29 | (NAND) and storage_usb (USB device). 30 | 31 | Each scan is valid unless you install/uninstall games on your Wii-U and only the last one will be use by the other scripts. 32 | During this process, necessary onlines files are dumped in _BatchFw_WiiU\OnlineFiles 33 | 34 | --------------------------------------------------------- 35 | Get online files : _BatchFw_WiiU\OnlineFiles 36 | --------------------------------------------------------- 37 | To dump files needed for playing online with Cemu : 38 | - CCERTS 39 | - SCERTS 40 | - MIIH 41 | - Friends list 42 | - accounts 43 | 44 | This script will also launch the following : 45 | 46 | --------------------------------------------------------- 47 | Associate BatchFw's user to Wii-U accounts : _BatchFw_WiiU\OnlineFiles\usersAccounts 48 | --------------------------------------------------------- 49 | This script associate BatchFw's users to Wii-U accounts. 50 | Once done, files (account.dat) are automatically installed when launching Cemu. 51 | You'll received a warning if your Wii-U is detected on the network to ensure that no one is using 52 | your account Id at the same time (risk of ban) 53 | 54 | --------------------------------------------------------- 55 | Import saves from my Wii-U : 56 | --------------------------------------------------------- 57 | The script will use the last scan results (or your can launch a new scan) to be sure that the game is 58 | installed on your Wii-U AND on your PC then import the saves for all users that have an accountId (so an associated 59 | folder 80000XX) and saves for this game. 60 | For all user, their folders are replaced by 8000001 (the only user CEMU handle in old versions) and the saveInfo.xml file 61 | is updated (only one user = 8000001). 62 | 63 | You can choose to syncronize your saves : continue to play Wii-U saves with CEMU (but your CEMU's save will be lost, in 64 | fact backuped under _BatchFw_WiiU\ImportSave) 65 | Since BatchFw introduce extra save slots, you can choose to create a slot to continue to play both saves with CEMU. 66 | 67 | In this mode, BatchFw will try to find an existing slot defined with a label containing "Wii-U import" 68 | and use it. If not found : 69 | * if a default user save exists : it will create automatically a slot labelled "Wii-U import @DATE" and activate it (use it) 70 | * no CEMU saves exists for the user: the Wii-U save will become the CEMU one (without creating a slot for this game) 71 | 72 | Have a look to the documentation in userSavesAndSlots.txt for further informations. 73 | 74 | --------------------------------------------------------- 75 | Export Cemu saves to my Wii-U : 76 | --------------------------------------------------------- 77 | Browse for a game in your library for which you want export saves to your Wii-U. 78 | The script will use the last scan results (or your can launch a new scan) to be sure that the game is installed on your Wii-U and your PC 79 | then export the saves for all users that have an accountId (so an associated folder 80000XX) and saves for this game. 80 | 81 | --------------------------------------------------------- 82 | Dumping games : 83 | --------------------------------------------------------- 84 | Using the last scan result, BatchFw will download a list of games (game's file + update + DLC + saves for all profiles) 85 | 86 | -------------------------------------------------------------------------------- /doc/updateGamesGraphicPacks.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/doc/updateGamesGraphicPacks.png -------------------------------------------------------------------------------- /doc/updateInstallUse.txt: -------------------------------------------------------------------------------- 1 | ========================================================= 2 | INSTALL-UPDATE-USE : 3 | ========================================================= 4 | 5 | --------------------------------------------------------- 6 | INSTALL : 7 | --------------------------------------------------------- 8 | 9 | Extract the archive's contain in your loadiine's games folder, then go in _BatchFW_Install and launch Setup.bat 10 | 11 | On the first install, you can display this documentation and the BatchFW_readme.txt file is build. 12 | Then setup.bat will run in SILENT mode. 13 | 14 | When answering questions in setup.bat, a log file for your current host is created under _BatchFW_Install. 15 | Never delete this file! It contains your host's settings (fullscreen mode, desired aspect ratio, GLCache path...) 16 | 17 | During the setup, you'll define an ouput (shortcut or executables) folder for all the CEMU's installs to use but also: 18 | - check and update _BatchFW_Graphic_Packs folder; 19 | - browse to a folder containing mods for your games so they will be copied under each game's folder; 20 | - if you want to run CEMU in fullscreen or in windowed mode; 21 | - if you let BatchFw completes your graphic packs (GFX) presets (V3) or create intermediates packs (V2); 22 | - your desired display aspect ratios (only if you has chosen the previous option); 23 | - the number of users to create (each user uses his own saves when launching his shortcut); 24 | - to define an ordered list of third party software (DS4windows, CemuGyro, SepeedHack...) to launch before CEMU in 25 | the order defined after checking if the program is not already running; 26 | - use externals mlc01 paths to copy/move saves, updates and DLC under each game's folder; 27 | - use your CEMU's mlc01 subfolder as well; 28 | 29 | Once the setup is finished, the output folder is opened in a windows explorer. 30 | It contains: 31 | - shortcuts to BatchFw logs, readmes and tools ; 32 | - a CEMU folder that contains a subfolder for each version registered containing: 33 | * a shorctut for editing the log of this version (log of the last launch); 34 | * a shortcut to the script that deletes your settings for this version and each games (selected); 35 | * a gameProfiles sufolder containing shortcuts to edit example.ini and the profile files of your games 36 | and also a shortcut to delete settings for all your games and for all versions of CEMU you have registered. 37 | 38 | Note: this folder contains only links or useless data and can be deleted to be fully recreated). 39 | 40 | 41 | RECOMMENDATIONS: 42 | 43 | To be fully functional BatchFw needs that you register the last(s) version(s) of CEMU you used to play your games. 44 | If you're using more the one version of CEMU (on version per game for example) register all installations and select 45 | the games to associated with those versions. 46 | 47 | If you're using one version of CEMU per player (and handle differents saves this way) : register this version for one user 48 | and use the shortcut "Wii-U Games\BatchFW\Tools\Games's saves\Import Saves" to import saves for other users afterward. 49 | 50 | --------------------------------------------------------- 51 | UPDATE : 52 | --------------------------------------------------------- 53 | 54 | BatchFW comes with an auto-updater 55 | 56 | --------------------------------------------------------- 57 | USE : 58 | --------------------------------------------------------- 59 | 60 | You don't need to manually open CEMU UI to play your game anymore. 61 | Once you have collected all the settings (on the first launch of a game) for all versions of CEMU you play on, use the shortcuts 62 | on your desktop (Or your shortcuts folder). 63 | 64 | You want to create shortcuts to all your games for versions of CEMU using the ones created after the installation on your desktop?: 65 | 66 | "Wii-U Games\BatchFW\Create CEMU's shortcuts for selected games.lnk" for a single CEMU version; 67 | "Wii-U Games\BatchFW\Set BatchFw settings and register CEMU installs.lnk" for more than one version (call setup.bat 68 | in silent mode); 69 | 70 | You want to : 71 | - change the way how Cemu is launched?: delete the shortcuts and re-create them; 72 | - delete your settings for version X.Y.Z or you want to recreate them?: use "Wii-U Games\CEMU\cemu_X.Y.Z\Delete my cemu_X.Y.Z's settings.lnk"; 73 | - add a game?: 74 | * use "Wii-U Games\Import Games with updates and DLC.lnk" to browse to a folder that contains games, updates and DLC 75 | BatchFW will ties all new games in your games folder with installing their updates and DLC in each game's folder 76 | * once new games copied in your games folder, create shortcuts for those games 77 | - remove a game from your library?: simply delete its created shortcut (BatchFw's broken shortcuts appear as the others ones, but without icon); 78 | 79 | With BatchFw, to backup fully a game (saves + update + DLC + transferable cache + controller settings...) just compress your game's folder 80 | 81 | Since V11, "how to" informations are displayed in the console when creating shortcuts. 82 | 83 | BatchFW come with an embeded graphic pack folder (_BatchFW_Graphic_Packs) created during setup.bat 84 | It checks for a graphic packs update availability (on eSlashiee repository) and update its packs 85 | Only graphic packs of the games you use are kept in _BatchFW_Graphic_Packs and in CEMU UI only the one for the game launched are displayed 86 | 87 | There's a specific documentation detailling graphic packs handling in BatchFW. 88 | 89 | Your open GLCache is backuped under %USERPROFILE%\AppData\Roaming OR local\%GPU_VENDOR%\_BatchFW_CemuGLCache per game,for all your game and 90 | for all GPU users. 91 | 92 | If you run an NVIDIA GPU, you can choose to disable automatically the precompiled cache for all your games (batchFw will patch CemuHook 93 | files and CEMU's game profile) 94 | So you go only with your GPU cache, saving space on your device by not duplicating the compiled shaders cache and making it compatible 95 | with all version of CEMU. 96 | This cache is valid unless you update your display's drivers : no need to fully recompile each cache for each game on each CEMU's version 97 | like when using the precompiled shader cache) 98 | When you update your drivers, batchFW will automically detect the new cache to backup and remove the old one. 99 | 100 | Disabling precompiled cache is not proposed to AMD's GPU because of their 64Mo size cache limitation. But the GLCache is even backuped. 101 | 102 | If you run an iGPU (Intel graphics), you will be asked to use the -noLegacy CEMU's option (-Legacy if CemuW 1.15) 103 | 104 | AUTOMATIC_IMPORT : 105 | 106 | This process is enabled by default. 107 | If any settings are already saved for a game, BatchFw will try to use them avoiding you to collect settings from scratch. 108 | It begins with the newer versions down to the the last ones. 109 | One or two checks are done (depending on the couple of versions checked) to decide if the import of the source is valid or not : 110 | - bin files size check: if source file's size is striclty lower than target's one => invalid import 111 | - if bin files check is OK, check if all criticals nodes (settings ones only) in xml target file exist in source file, if not => invalid import 112 | 113 | In addition, on last versions of CEMU, its auto-updater handle the settings.xml file upgrade. 114 | 115 | WARNING : Do not delete log files created under ./logs 116 | If you need to reset BatchFw to default, use the shortcut "Wii-U Games\BatchFW\Reset BatchFw.lnk" 117 | 118 | 119 | --------------------------------------------------------- 120 | UNINSTALL : 121 | --------------------------------------------------------- 122 | 123 | Launch uninstall.bat from your desktop : "Wii-U Games\BatchFW\Uninstall BatchFW" 124 | 125 | -------------------------------------------------------------------------------- /doc/userSavesAndSlots.txt: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/doc/userSavesAndSlots.txt -------------------------------------------------------------------------------- /resources/BRC_Unicode_64/BRC64.exe: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/BRC_Unicode_64/BRC64.exe -------------------------------------------------------------------------------- /resources/BRC_Unicode_64/pcre.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/BRC_Unicode_64/pcre.dll -------------------------------------------------------------------------------- /resources/Bat_To_Exe_Converter.exe: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/Bat_To_Exe_Converter.exe -------------------------------------------------------------------------------- /resources/BatchFw.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/BatchFw.png -------------------------------------------------------------------------------- /resources/GFX_Packs.rar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/GFX_Packs.rar -------------------------------------------------------------------------------- /resources/JNUST/JNUSTool.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/JNUST/JNUSTool.jar -------------------------------------------------------------------------------- /resources/JNUST/JNUSTool.txt: -------------------------------------------------------------------------------- 1 | 2. Command line (when you want to provide a key or use a titleid that is not in the list) 2 | Code: 3 | 4 | java -jar JNUSTool.jar TITLEID 5 | 6 | Replace the TITLEID with the title id you want to download (e.g. 0005000E1011A700). You can also add a version number ("v" prefix). e.g. 7 | Code: 8 | 9 | java -jar JNUSTool.jar 0005000E1011A700 v16 10 | 11 | To download the encrypted data, just append the string "-dlEncrypted". 12 | Code: 13 | 14 | java -jar JNUSTool.jar 0005000E1011A700 v16 -dlEncrypted 15 | 16 | You can download decrypted files via comandline with the -file argument. The argument after -files is regular expression that will be used. 17 | 18 | Example for downloading the app.xml only 19 | Code: 20 | 21 | java -jar JNUSTool.jar 0005000E1011A700 -file /code/app.xml 22 | 23 | Example for downloading the code folder only 24 | Code: 25 | 26 | java -jar JNUSTool.jar 0005000E1011A700 -file /code/.* 27 | 28 | Example for downloading all .szs files 29 | Code: 30 | 31 | java -jar JNUSTool.jar 0005000E1011A700 -file .*.szs 32 | 33 | To decrypted encrypted data, put the files into a created "tmp_TITLEID" folder. For example when you have the title id "0005000012345678" out the files in the folder "tmp_0005000012345678" and do: 34 | Code: 35 | 36 | java -jar JNUSTool.jar 0005000012345678 37 | 38 | -------------------------------------------------------------------------------- /resources/JNUST/WudCompress.exe: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/JNUST/WudCompress.exe -------------------------------------------------------------------------------- /resources/JNUST/wud2app.exe: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/JNUST/wud2app.exe -------------------------------------------------------------------------------- /resources/Quick_Any2Ico.exe: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/Quick_Any2Ico.exe -------------------------------------------------------------------------------- /resources/Quick_Any2Ico.txt: -------------------------------------------------------------------------------- 1 | Command line reference 2 | Quick Any2Ico can be used to create ICO/PNG files from the command line or a batch script. The supported command line switches are: 3 | 4 | Quick_Any2Ico.exe "-img=Source image" "-icon=Dest. icon/png" -formats=IconFormats -pngc -crop -stretch 5 | OR 6 | Quick_Any2Ico.exe "-res=Resource file" "-icon=Dest. icon/png" -formats=IconFormats -pngc -crop -stretch 7 | 8 | "-img=Source image" : This switch specifies the image file to convert. If the image file path or name has white spaces, you must 9 | enclose the entire switch with double quotes. Example: "-img=C:\My picture.png" or -img=C:\MyPic.png. 10 | 11 | "-icon=Dest. icon/png" : This switch specifies the destination ICO or PNG file. If the icon file path or name has white spaces, you 12 | must enclose the entire switch with double quotes. Example: "-icon=C:\My icon.ico" or -icon=C:\MyIcon.png. 13 | 14 | -formats=IconFormats : (Optional) This switch specifies the image fomats for the icon file. Several formats must be coma separated 15 | and there must be no white spaces between the characters. Valid values are 16,24,32,48,64,72,96,128,256,512. If this parameter is not 16 | specified, the default sizes are applied: 16,32,48,256. 17 | 18 | -pngc : (Optional) This switch specifies that large formats should be PNG compressed. Not valid fot PNG destination files. 19 | -crop : (Optional) This switch specifies that if the source image is not squared, it should be cropped to fill the icon's square. 20 | -stretch : (Optional) This switch specifies that if the source image is not squared, it should be stretched to fill the icon's square. 21 | 22 | If neither -crop or -stretch are specified, the image is centered. 23 | "-res=Resource file" : This switch specifies the resource file that contains the icon to be extracted. If the resource file path or 24 | name has white spaces, you must enclose the entire switch with double quotes. To specify the index of the icon to be extracted, append a 25 | coma and the zero based index of the icon. Example: -res=Shell32.dll,17 or "-res=C:\My program.exe,2". 26 | Obviously you can't specify both "-img=Source image" and "-res=Resource file". If you do, "-res=Resource file" will be used. 27 | 28 | The quick examples below will hopefully ilustrate more accurately how the command line switches work. 29 | 30 | The command below will extract the 15th icon from shell32.dll with PNG compression and the formats 32x32, 48x48 and 256x256. 31 | Quick_Any2Ico.exe -res=Shell32.dll,14 -icon=Shell32.ico -formats=32,48,256 -pngc 32 | 33 | The command below will convert the C:\My image.png picture to C:\My Icon.ico with the default formats and crop it to fit the icon's square. 34 | Quick_Any2Ico.exe "-img=C:\My image.png" "icon=C:\My Icon.ico" -crop 35 | 36 | Quick_Any2Ico.exe "-res=!program:"=!,1" "-icon=!ICO_PATH:"=!" -formats=256 37 | -------------------------------------------------------------------------------- /resources/Rar.exe: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/Rar.exe -------------------------------------------------------------------------------- /resources/V2_GFX_Packs.rar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/V2_GFX_Packs.rar -------------------------------------------------------------------------------- /resources/V4_GFX_Packs.rar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/V4_GFX_Packs.rar -------------------------------------------------------------------------------- /resources/WiiU-Titles-Library.csv: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/WiiU-Titles-Library.csv -------------------------------------------------------------------------------- /resources/WiiuSDcard.rar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/WiiuSDcard.rar -------------------------------------------------------------------------------- /resources/cemuhook_1116_0564.rar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/cemuhook_1116_0564.rar -------------------------------------------------------------------------------- /resources/cemuhook_1159_0573.rar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/cemuhook_1159_0573.rar -------------------------------------------------------------------------------- /resources/cemuhook_1251_0574.rar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/cemuhook_1251_0574.rar -------------------------------------------------------------------------------- /resources/cmdow.exe: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/cmdow.exe -------------------------------------------------------------------------------- /resources/convert.exe: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/convert.exe -------------------------------------------------------------------------------- /resources/du.exe: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/du.exe -------------------------------------------------------------------------------- /resources/fat32format.exe: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/fat32format.exe -------------------------------------------------------------------------------- /resources/fnr.exe: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/fnr.exe -------------------------------------------------------------------------------- /resources/gamesIcons/Readme.txt: -------------------------------------------------------------------------------- 1 | Here will be placed icons converted from jpg box art of the games (when meta/iconTex.tga is missing) -------------------------------------------------------------------------------- /resources/getShaderCacheName/getShaderCacheName.exe: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/getShaderCacheName/getShaderCacheName.exe -------------------------------------------------------------------------------- /resources/getShaderCacheName/main.c: -------------------------------------------------------------------------------- 1 | #include 2 | #include 3 | 4 | typedef signed long sint32; 5 | 6 | typedef unsigned char uint8; 7 | typedef unsigned long uint32; 8 | 9 | /************************ FUNCTIONS *************************/ 10 | 11 | uint32 generateHashFromRawRPXData(uint8* rpxData, sint32 size) 12 | { 13 | uint32 h = 0x3416DCBF; 14 | for (sint32 i = 0; i < size; i++) 15 | { 16 | uint32 c = rpxData[i]; 17 | h = (h << 3) | (h >> 29); 18 | h += c; 19 | } 20 | return h; 21 | } 22 | 23 | void display(char* file, sint32 size, uint32 nameDec) 24 | { 25 | // printf("\nfile=%s\n", file); 26 | 27 | // display file size 28 | // printf("size=%ld\n", size); 29 | // validate : BOTW V208 EUR : shaderCacheName=3702298919; 30 | 31 | // printf("shaderCacheName=%ld\n", nameDec); 32 | char res[9]; /* four bytes of hex = 8 characters, plus NULL terminator */ 33 | 34 | if (nameDec <= 0xFFFFFFFF) 35 | { 36 | sprintf(&res[0], "%08x", (unsigned int) nameDec); 37 | } 38 | 39 | for (uint8 i=0; i<9; i++) { 40 | printf("%c", res[i]); 41 | } 42 | } 43 | /*************************** MAIN ***************************/ 44 | int main(int argc, char** argv) 45 | { 46 | // file size 47 | sint32 sz=0; 48 | // file data 49 | uint8 *rpxData=NULL; 50 | // shaderCacheName 51 | uint32 shaderCacheName=0; 52 | 53 | // open rpx file 54 | FILE *fl = fopen(argv[1], "rb"); 55 | fseek(fl, 0, SEEK_END); 56 | sz = ftell(fl); 57 | 58 | rpxData = malloc(sz); 59 | if (!rpxData) 60 | { 61 | printf("Error when allocating rpxData !\n"); 62 | return 1; 63 | } 64 | rewind(fl); 65 | 66 | fread(rpxData, 1, sz, fl); 67 | fclose(fl); 68 | 69 | // compute custom hash (CEMU) 70 | shaderCacheName=generateHashFromRawRPXData(rpxData,sz); 71 | // deallocation 72 | free(rpxData); 73 | 74 | display(argv[1], sz, shaderCacheName); 75 | 76 | return 0; 77 | } 78 | -------------------------------------------------------------------------------- /resources/icons/BatchFw.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/icons/BatchFw.ico -------------------------------------------------------------------------------- /resources/icons/BatchFw.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/icons/BatchFw.png -------------------------------------------------------------------------------- /resources/icons/Cemu.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/icons/Cemu.ico -------------------------------------------------------------------------------- /resources/icons/DS4Windows.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/icons/DS4Windows.ico -------------------------------------------------------------------------------- /resources/icons/ImportSave.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/icons/ImportSave.ico -------------------------------------------------------------------------------- /resources/icons/ImportSaves.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/icons/ImportSaves.ico -------------------------------------------------------------------------------- /resources/icons/Wii-U Error Codes.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/icons/Wii-U Error Codes.ico -------------------------------------------------------------------------------- /resources/icons/WiiU-user.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/icons/WiiU-user.ico -------------------------------------------------------------------------------- /resources/icons/WiiU-user.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/icons/WiiU-user.png -------------------------------------------------------------------------------- /resources/icons/WiiU.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/icons/WiiU.png -------------------------------------------------------------------------------- /resources/icons/WiiUfwuOff.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/icons/WiiUfwuOff.ico -------------------------------------------------------------------------------- /resources/icons/WiiUfwuOff.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/icons/WiiUfwuOff.png -------------------------------------------------------------------------------- /resources/icons/WiiUfwuOn.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/icons/WiiUfwuOn.ico -------------------------------------------------------------------------------- /resources/icons/WiiUfwuOn.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/icons/WiiUfwuOn.png -------------------------------------------------------------------------------- /resources/icons/WinSCP.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/icons/WinSCP.ico -------------------------------------------------------------------------------- /resources/icons/Wud2Rpx.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/icons/Wud2Rpx.ico -------------------------------------------------------------------------------- /resources/icons/Wud2Wup.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/icons/Wud2Wup.ico -------------------------------------------------------------------------------- /resources/icons/Wud2Wux.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/icons/Wud2Wux.ico -------------------------------------------------------------------------------- /resources/icons/WudxWup.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/icons/WudxWup.ico -------------------------------------------------------------------------------- /resources/icons/Wup2Rpx.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/icons/Wup2Rpx.ico -------------------------------------------------------------------------------- /resources/icons/Wux2Rpx.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/icons/Wux2Rpx.ico -------------------------------------------------------------------------------- /resources/icons/Wux2Wud.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/icons/Wux2Wud.ico -------------------------------------------------------------------------------- /resources/icons/backupAllInGameSaves.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/icons/backupAllInGameSaves.ico -------------------------------------------------------------------------------- /resources/icons/buildExtraGraphicPacks.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/icons/buildExtraGraphicPacks.ico -------------------------------------------------------------------------------- /resources/icons/cemu.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/icons/cemu.png -------------------------------------------------------------------------------- /resources/icons/compress.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/icons/compress.ico -------------------------------------------------------------------------------- /resources/icons/compress.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/icons/compress.png -------------------------------------------------------------------------------- /resources/icons/convertIconsForAllGames.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/icons/convertIconsForAllGames.ico -------------------------------------------------------------------------------- /resources/icons/copyMlc01DataForAllGames.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/icons/copyMlc01DataForAllGames.ico -------------------------------------------------------------------------------- /resources/icons/createExecutables.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/icons/createExecutables.ico -------------------------------------------------------------------------------- /resources/icons/createGameGraphicPacks.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/icons/createGameGraphicPacks.ico -------------------------------------------------------------------------------- /resources/icons/createShortcuts.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/icons/createShortcuts.ico -------------------------------------------------------------------------------- /resources/icons/delete.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/icons/delete.ico -------------------------------------------------------------------------------- /resources/icons/deleteAllInGameSaves.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/icons/deleteAllInGameSaves.ico -------------------------------------------------------------------------------- /resources/icons/deleteAllInGameSavesBackup.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/icons/deleteAllInGameSavesBackup.ico -------------------------------------------------------------------------------- /resources/icons/deleteAllMySettings.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/icons/deleteAllMySettings.ico -------------------------------------------------------------------------------- /resources/icons/deleteGamesShortcuts.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/icons/deleteGamesShortcuts.ico -------------------------------------------------------------------------------- /resources/icons/deleteGamesShortcuts.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/icons/deleteGamesShortcuts.png -------------------------------------------------------------------------------- /resources/icons/deleteMyGLCacheBackup.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/icons/deleteMyGLCacheBackup.ico -------------------------------------------------------------------------------- /resources/icons/deleteMyGpuCache.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/icons/deleteMyGpuCache.ico -------------------------------------------------------------------------------- /resources/icons/disableProgressBar.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/icons/disableProgressBar.ico -------------------------------------------------------------------------------- /resources/icons/displayGamesStats.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/icons/displayGamesStats.ico -------------------------------------------------------------------------------- /resources/icons/displayGamesStats.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/icons/displayGamesStats.png -------------------------------------------------------------------------------- /resources/icons/download.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/icons/download.ico -------------------------------------------------------------------------------- /resources/icons/downloadGames.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/icons/downloadGames.ico -------------------------------------------------------------------------------- /resources/icons/enableProgressBar.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/icons/enableProgressBar.ico -------------------------------------------------------------------------------- /resources/icons/exploreOpenGLCacheSaves.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/icons/exploreOpenGLCacheSaves.ico -------------------------------------------------------------------------------- /resources/icons/exportAllToCemu.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/icons/exportAllToCemu.ico -------------------------------------------------------------------------------- /resources/icons/exportSave.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/icons/exportSave.ico -------------------------------------------------------------------------------- /resources/icons/exportSave.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/icons/exportSave.png -------------------------------------------------------------------------------- /resources/icons/exportUserGamesStatsToCemu.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/icons/exportUserGamesStatsToCemu.ico -------------------------------------------------------------------------------- /resources/icons/fixBrokenShortcuts.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/icons/fixBrokenShortcuts.ico -------------------------------------------------------------------------------- /resources/icons/fixBrokenShortcuts.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/icons/fixBrokenShortcuts.png -------------------------------------------------------------------------------- /resources/icons/forceGraphicPackUpdate.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/icons/forceGraphicPackUpdate.ico -------------------------------------------------------------------------------- /resources/icons/getMyShaderCachesSize.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/icons/getMyShaderCachesSize.ico -------------------------------------------------------------------------------- /resources/icons/getTitleDataFromLibrary.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/icons/getTitleDataFromLibrary.ico -------------------------------------------------------------------------------- /resources/icons/importGames.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/icons/importGames.ico -------------------------------------------------------------------------------- /resources/icons/importModsForAllGames.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/icons/importModsForAllGames.ico -------------------------------------------------------------------------------- /resources/icons/importSave.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/icons/importSave.ico -------------------------------------------------------------------------------- /resources/icons/importSave.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/icons/importSave.png -------------------------------------------------------------------------------- /resources/icons/importTransferableCache.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/icons/importTransferableCache.ico -------------------------------------------------------------------------------- /resources/icons/kill.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/icons/kill.ico -------------------------------------------------------------------------------- /resources/icons/kill.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/icons/kill.png -------------------------------------------------------------------------------- /resources/icons/moveMlc01DataForAllGames.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/icons/moveMlc01DataForAllGames.ico -------------------------------------------------------------------------------- /resources/icons/noIconFound.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/icons/noIconFound.ico -------------------------------------------------------------------------------- /resources/icons/notepad.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/icons/notepad.ico -------------------------------------------------------------------------------- /resources/icons/online.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/icons/online.ico -------------------------------------------------------------------------------- /resources/icons/online.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/icons/online.jpg -------------------------------------------------------------------------------- /resources/icons/restoreBfwDefaultSettings.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/icons/restoreBfwDefaultSettings.ico -------------------------------------------------------------------------------- /resources/icons/restoreMlc01DataForAllGames.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/icons/restoreMlc01DataForAllGames.ico -------------------------------------------------------------------------------- /resources/icons/restoreTransShadersForAllGames.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/icons/restoreTransShadersForAllGames.ico -------------------------------------------------------------------------------- /resources/icons/restoreUserSavesOfAllGames.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/icons/restoreUserSavesOfAllGames.ico -------------------------------------------------------------------------------- /resources/icons/save.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/icons/save.jpg -------------------------------------------------------------------------------- /resources/icons/saveSlots.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/icons/saveSlots.ico -------------------------------------------------------------------------------- /resources/icons/scanResults.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/icons/scanResults.ico -------------------------------------------------------------------------------- /resources/icons/scanResults.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/icons/scanResults.png -------------------------------------------------------------------------------- /resources/icons/sdcard.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/icons/sdcard.ico -------------------------------------------------------------------------------- /resources/icons/sdcard.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/icons/sdcard.png -------------------------------------------------------------------------------- /resources/icons/settings.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/icons/settings.png -------------------------------------------------------------------------------- /resources/icons/setup.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/icons/setup.ico -------------------------------------------------------------------------------- /resources/icons/syncGamesFolder.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/icons/syncGamesFolder.ico -------------------------------------------------------------------------------- /resources/icons/syncGamesFolder.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/icons/syncGamesFolder.png -------------------------------------------------------------------------------- /resources/icons/uninstall.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/icons/uninstall.ico -------------------------------------------------------------------------------- /resources/icons/updateGames.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/icons/updateGames.ico -------------------------------------------------------------------------------- /resources/icons/updateGraphicPacksFolder.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/icons/updateGraphicPacksFolder.ico -------------------------------------------------------------------------------- /resources/icons/upload.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/icons/upload.ico -------------------------------------------------------------------------------- /resources/icons/wii-u.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/icons/wii-u.ico -------------------------------------------------------------------------------- /resources/icons/wii-u.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/icons/wii-u.png -------------------------------------------------------------------------------- /resources/icons/wipe.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/icons/wipe.ico -------------------------------------------------------------------------------- /resources/icons/wipe.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/icons/wipe.png -------------------------------------------------------------------------------- /resources/ps1/getLatestBFW.ps1: -------------------------------------------------------------------------------- 1 | # This script output the latest release file 2 | [Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tls12 3 | 4 | try { 5 | 6 | $latestRelease = Invoke-WebRequest -UseBasicParsing https://github.com/Laf111/CEMU-Batch-Framework/releases/latest -Headers @{"Accept"="application/json"} 7 | # The releases are returned in the format {"id":3622206,"tag_name":"hello-1.0.0.11",...}, we have to extract the tag_name. 8 | } catch { 9 | # Dig into the exception to get the Response details. 10 | # Note that value__ is not a typo. 11 | Exit 1 12 | } 13 | 14 | $json = $latestRelease.Content | ConvertFrom-Json 15 | $latestVersion = $json.tag_name 16 | 17 | Write-Host $latestVersion 18 | 19 | Exit $LASTEXITCODE 20 | -------------------------------------------------------------------------------- /resources/ps1/getLatestGP.ps1: -------------------------------------------------------------------------------- 1 | # This script output the latest release file 2 | [Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tls12 3 | 4 | try { 5 | 6 | $latestRelease = Invoke-WebRequest -UseBasicParsing https://github.com/slashiee/cemu_graphic_packs/releases/latest -Headers @{"Accept"="application/json"} 7 | # The releases are returned in the format {"id":3622206,"tag_name":"hello-1.0.0.11",...}, we have to extract the tag_name. 8 | } catch { 9 | # Dig into the exception to get the Response details. 10 | # Note that value__ is not a typo. 11 | Write-Host "Connexion failed !" 12 | Write-Host "StatusCode:" $_.Exception.Response.StatusCode.value__ 13 | Write-Host "StatusDescription:" $_.Exception.Response.StatusDescription 14 | Exit 1 15 | } 16 | 17 | $json = $latestRelease.Content | ConvertFrom-Json 18 | $latestVersion = $json.tag_name 19 | $pos = $latestVersion.IndexOf("Github") 20 | $leftPart = $latestVersion.Substring(0, $pos) 21 | $rightPart = $latestVersion.Substring($pos+6) 22 | $latest = "graphicPacks" + $rightPart + ".zip" 23 | 24 | Write-Host $latest 25 | 26 | Exit $LASTEXITCODE 27 | -------------------------------------------------------------------------------- /resources/ps1/updateBFW.ps1: -------------------------------------------------------------------------------- 1 | # This script have to be copied in _BatchFW_Graphic_Packs 2 | [Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tls12 3 | 4 | $latestRelease = Invoke-WebRequest -UseBasicParsing https://github.com/Laf111/CEMU-Batch-Framework/releases/latest -Headers @{"Accept"="application/json"} 5 | # The releases are returned in the format {"id":3622206,"tag_name":"hello-1.0.0.11",...}, we have to extract the tag_name. 6 | $json = $latestRelease.Content | ConvertFrom-Json 7 | $latestVersion = $json.tag_name 8 | 9 | $url = "https://github.com/Laf111/CEMU-Batch-Framework/releases/download/" + $latestVersion + "/CEMU_BatchFW_" + $latestVersion + ".zip" 10 | 11 | # --- Download the file to the current location 12 | $OutputPath = "$((Get-Location).Path)\CEMU_BatchFW_" + $latestVersion + ".zip" 13 | 14 | try { 15 | Invoke-RestMethod -Method Get -Uri $url -OutFile $OutputPath 16 | } catch { 17 | # Dig into the exception to get the Response details. 18 | # Note that value__ is not a typo. 19 | Write-Host "Connexion failed !" 20 | Write-Host "StatusCode:" $_.Exception.Response.StatusCode.value__ 21 | Write-Host "StatusDescription:" $_.Exception.Response.StatusDescription 22 | Exit 1 23 | } 24 | 25 | Expand-Archive -Path $OutputPath -DestinationPath $((Get-Location).Path) -Force 26 | $cr=$LASTEXITCODE 27 | If ($cr -eq 1) { 28 | Write-Host "Error when uncompressing "$OutputPath" !" 29 | Exit 2 30 | } 31 | Remove-Item $OutputPath 32 | Write-host "BFW_VERSION="+$latestVersion 33 | 34 | Exit $LASTEXITCODE 35 | -------------------------------------------------------------------------------- /resources/ps1/updateGP.ps1: -------------------------------------------------------------------------------- 1 | # This script have to be copied in _BatchFW_Graphic_Packs 2 | [Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tls12 3 | 4 | $latestRelease = Invoke-WebRequest -UseBasicParsing https://github.com/slashiee/cemu_graphic_packs/releases/latest -Headers @{"Accept"="application/json"} 5 | # The releases are returned in the format {"id":3622206,"tag_name":"hello-1.0.0.11",...}, we have to extract the tag_name. 6 | $json = $latestRelease.Content | ConvertFrom-Json 7 | $latestVersion = $json.tag_name 8 | $pos = $latestVersion.IndexOf("Github") 9 | $leftPart = $latestVersion.Substring(0, $pos) 10 | $rightPart = $latestVersion.Substring($pos+6) 11 | $url = "https://github.com/slashiee/cemu_graphic_packs/releases/download/$latestVersion/graphicPacks" + $rightPart + ".zip" 12 | 13 | # --- Download the file to the current location 14 | $OutputPath = "$((Get-Location).Path)\graphicPacks" + $rightPart + ".zip" 15 | 16 | try { 17 | Invoke-RestMethod -Method Get -Uri $url -OutFile $OutputPath 18 | } catch { 19 | # Dig into the exception to get the Response details. 20 | # Note that value__ is not a typo. 21 | Write-Host "Connexion failed !" 22 | Write-Host "StatusCode:" $_.Exception.Response.StatusCode.value__ 23 | Write-Host "StatusDescription:" $_.Exception.Response.StatusDescription 24 | Exit 1 25 | } 26 | 27 | Write-host $OutputPath" succesfully download from "$url 28 | 29 | Expand-Archive -Path $OutputPath -DestinationPath $((Get-Location).Path) -Force 30 | $cr=$LASTEXITCODE 31 | If ($cr -eq 1) { 32 | Write-Host "Error when uncompressing "$OutputPath" !" 33 | Exit 2 34 | } 35 | Remove-Item $OutputPath 36 | $LogPath = "graphicPacks" + $rightPart + ".doNotDelete" 37 | New-Item -Path . -Name $LogPath -ItemType file 38 | 39 | Exit $LASTEXITCODE 40 | -------------------------------------------------------------------------------- /resources/sharedFonts.rar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/sharedFonts.rar -------------------------------------------------------------------------------- /resources/vbs/BrowseFileDialog.vbs: -------------------------------------------------------------------------------- 1 | Option Explicit 2 | 3 | Dim strFile 4 | 5 | strFile = SelectFile( ) 6 | 7 | If strFile = "" Then 8 | WScript.Echo """NONE""" 9 | Else 10 | WScript.Echo """" & Replace(strFile," ","?") & """" 11 | End If 12 | 13 | Function SelectFile( ) 14 | ' File Browser via HTA 15 | ' Author: Rudi Degrande, modifications by Denis St-Pierre and Rob van der Woude 16 | ' Features: Works in Windows Vista and up (Should also work in XP). 17 | ' Fairly fast. 18 | ' All native code/controls (No 3rd party DLL/ XP DLL). 19 | ' Caveats: Cannot define default starting folder. 20 | ' Uses last folder used with MSHTA.EXE stored in Binary in [HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\ComDlg32]. 21 | ' Dialog title says "Choose file to upload". 22 | ' Source: https://social.technet.microsoft.com/Forums/scriptcenter/en-US/a3b358e8-15ae-4ba3-bca5-ec349df65ef6/windows7-vbscript-open-file-dialog-box-fakepath?forum=ITCG 23 | 24 | Dim objExec, strMSHTA, wshShell 25 | 26 | SelectFile = "" 27 | 28 | ' For use in HTAs as well as "plain" VBScript: 29 | strMSHTA = "mshta.exe ""about:" & "<" & "input type=file id=FILE>" _ 30 | & "<" & "script>FILE.click();new ActiveXObject('Scripting.FileSystemObject')" _ 31 | & ".GetStandardStream(1).WriteLine(FILE.value);close();resizeTo(0,0);" & "<" & "/script>""" 32 | ' For use in "plain" VBScript only: 33 | ' strMSHTA = "mshta.exe ""about:" _ 34 | ' & """" 36 | 37 | Set wshShell = CreateObject( "WScript.Shell" ) 38 | Set objExec = wshShell.Exec( strMSHTA ) 39 | 40 | SelectFile = objExec.StdOut.ReadLine( ) 41 | 42 | Set objExec = Nothing 43 | Set wshShell = Nothing 44 | End Function -------------------------------------------------------------------------------- /resources/vbs/BrowseFolderDialog.vbs: -------------------------------------------------------------------------------- 1 | Option Explicit 2 | 3 | Dim strPath, objArgs, messageText, myStartFolder 4 | 5 | Set objArgs = WScript.Arguments 6 | 7 | ' message 8 | messageText = objArgs(0) 9 | ' root folder 10 | myStartFolder="" 11 | If objArgs.Count=2 Then 12 | myStartFolder = objArgs(1) 13 | End If 14 | 15 | strPath = SelectFolder( myStartFolder, messageText ) 16 | If strPath = vbNull Then 17 | WScript.Echo """NONE""" 18 | Else 19 | WScript.Echo """" & Replace(strPath," ","?") & """" 20 | End If 21 | 22 | Function SelectFolder( myStartFolder, messageText ) 23 | ' This function opens a "Select Folder" dialog and will 24 | ' return the fully qualified path of the selected folder 25 | ' 26 | ' Argument: 27 | ' myStartFolder [string] the root folder where you can start browsing; 28 | ' if an empty string is used, browsing starts 29 | ' on the local computer 30 | ' 31 | ' Returns: 32 | ' A string containing the fully qualified path of the selected folder 33 | 34 | 35 | ' Standard housekeeping 36 | Dim objFolder, objItem, objShell 37 | 38 | ' Custom error handling 39 | On Error Resume Next 40 | SelectFolder = vbNull 41 | 42 | ' Create a dialog object 43 | 44 | 45 | Set objShell = CreateObject( "Shell.Application" ) 46 | Set objFolder = objShell.BrowseForFolder( 0, messageText, 0, myStartFolder ) 47 | 48 | ' Return the path of the selected folder 49 | If IsObject( objfolder ) Then SelectFolder = objFolder.Self.Path 50 | 51 | ' Standard housekeeping 52 | Set objFolder = Nothing 53 | Set objshell = Nothing 54 | On Error Goto 0 55 | End Function -------------------------------------------------------------------------------- /resources/vbs/MessageBox.vbs: -------------------------------------------------------------------------------- 1 | Set objArgs = WScript.Arguments 2 | Dim returnValue : returnValue = 0 3 | 4 | ' message 5 | messageText = objArgs(0) 6 | 7 | If (objArgs.Count = 1) Then 8 | createobject("wscript.shell").popup messageText, 20, "CEMU's BatchFw", 64 9 | Else 10 | If (objArgs.Count = 2) Then 11 | critLevel = objArgs(1) 12 | If (critLevel = "pop8sec") Then 13 | createobject("wscript.shell").popup messageText, 8, "CEMU's BatchFw", 64 14 | Else 15 | ' critLevel values : 16 | 17 | ' Constant Value Description 18 | ' ----------------------------------- 19 | ' vbOKOnly 0 Display OK button only. 20 | ' vbOKCancel 1 Display OK and Cancel buttons. 21 | ' vbAbortRetryIgnore 2 Display Abort, Retry, and Ignore buttons. 22 | ' vbYesNoCancel 3 Display Yes, No, and Cancel buttons. 23 | ' vbYesNo 4 Display Yes and No buttons. 24 | ' vbRetryCancel 5 Display Retry and Cancel buttons. 25 | ' vbCritical 16 Display Critical Message icon. 26 | ' vbQuestion 32 Display Warning Query icon. 27 | ' vbExclamation 48 Display Warning Message icon. 28 | ' vbInformation 64 Display Information Message icon. 29 | ' vbDefaultButton1 0 First button is default. 30 | ' vbDefaultButton2 256 Second button is default. 31 | ' vbDefaultButton3 512 Third button is default. 32 | ' vbDefaultButton4 768 Fourth button is default. 33 | ' vbApplicationModal 0 Application modal. The user must respond to the message box before continuing work in the current application. 34 | ' vbSystemModal 4096 System modal. On Microsoft Win16 systems, all applications are suspended until the user responds to the message box. 35 | ' On Microsoft Win32 systems, this constant provides an application modal message box that always remains on top of any other programs that you have running 36 | ' 37 | ' ex : 38 | ' vbOKOnly+vbCritical+vbSystemModal = 4112 39 | ' vbOKOnly+vbQuestion+vbSystemModal = 4128 40 | ' vbOKOnly+vbExclamation+vbSystemModal = 4144 41 | ' vbOKOnly+vbInformation+vbSystemModal = 4160 42 | ' 43 | ' vbRetryCancel+vbCritical+vbSystemModal = 4117 44 | ' vbRetryCancel+vbCritical+vbSystemModal+vbDefaultButton2 = 4373 45 | ' 46 | ' vbRetryCancel+vbQuestion+vbSystemModal = 4133 47 | ' vbRetryCancel+vbQuestion+vbSystemModal+vbDefaultButton2 = 4389 48 | ' 49 | ' vbRetryCancel+vbExclamation+vbSystemModal = 4149 50 | ' vbRetryCancel+vbExclamation+vbSystemModal+vbDefaultButton2 = 4405 51 | ' 52 | ' vbRetryCancel+vbInformation+vbSystemModal = 4165 53 | ' vbRetryCancel+vbInformation+vbSystemModal+vbDefaultButton2 = 4421 54 | 55 | ' open msg box 56 | returnValue = MsgBox(messageText, critLevel, "CEMU's BatchFw") 57 | 58 | ' The MsgBox function has the following return values: 59 | ' 60 | ' Constant Value Button 61 | ' -------------------------- 62 | ' vbOK 1 OK 63 | ' vbCancel 2 Cancel 64 | ' vbAbort 3 Abort 65 | ' vbRetry 4 Retry 66 | ' vbIgnore 5 Ignore 67 | ' vbYes 6 Yes 68 | ' vbNo 7 No 69 | 70 | End If 71 | End If 72 | End If 73 | 74 | WScript.Quit(returnValue) 75 | 76 | -------------------------------------------------------------------------------- /resources/vbs/Start.vbs: -------------------------------------------------------------------------------- 1 | ' this script launch a an external program 2 | Set WshShell = WScript.CreateObject("WScript.Shell") 3 | Set filesys = CreateObject("Scripting.FileSystemObject") 4 | Set objArgs = Wscript.Arguments 5 | For Each strArg in objArgs 6 | If (strLine = "") Then 7 | If filesys.FileExists(strArg) Then 8 | WshShell.CurrentDirectory = filesys.GetParentFolderName(strArg) 9 | Else 10 | MsgBox "ERROR : " & strArg & " does not exist", 4112, "CEMU's BatchFw" 11 | WScript.Quit(99) 12 | End If 13 | strLine = """" & strArg & """" 14 | Else 15 | strLine = strLine & " """ & strArg & """" 16 | End If 17 | Next 18 | intReturn = WshShell.Run(strLine, 1, false) 19 | WScript.Quit(intReturn) 20 | -------------------------------------------------------------------------------- /resources/vbs/StartHidden.vbs: -------------------------------------------------------------------------------- 1 | ' this script launch a an external program 2 | Set WshShell = WScript.CreateObject("WScript.Shell") 3 | Set filesys = CreateObject("Scripting.FileSystemObject") 4 | Set objArgs = Wscript.Arguments 5 | For Each strArg in objArgs 6 | If (strLine = "") Then 7 | If filesys.FileExists(strArg) Then 8 | WshShell.CurrentDirectory = filesys.GetParentFolderName(strArg) 9 | Else 10 | MsgBox "ERROR : " & strArg & " does not exist", 4112, "CEMU's BatchFw" 11 | End If 12 | strLine = """" & strArg & """" 13 | Else 14 | strLine = strLine & " """ & strArg & """" 15 | End If 16 | Next 17 | intReturn = WshShell.Run(strLine, 0, false) 18 | WScript.Quit(intReturn) 19 | -------------------------------------------------------------------------------- /resources/vbs/StartHiddenCmd.vbs: -------------------------------------------------------------------------------- 1 | ' this script launch a an external program 2 | Set WshShell = WScript.CreateObject("WScript.Shell") 3 | Set filesys = CreateObject("Scripting.FileSystemObject") 4 | Set objArgs = Wscript.Arguments 5 | 6 | For Each strArg in objArgs 7 | If (strLine = "") Then 8 | If filesys.FileExists(strArg) Then 9 | WshShell.CurrentDirectory = filesys.GetParentFolderName(strArg) 10 | Else 11 | MsgBox "ERROR : " & strArg & " does not exist", 4112, "CEMU's BatchFw" 12 | WScript.Quit(99) 13 | End If 14 | strLine = """" & strArg & """" 15 | Else 16 | strLen=Len(strArg) 17 | If (strLen >= 2) then 18 | If (Mid(strArg,2,1) = ":") then 19 | strLine = strLine & " """ & strArg & """" 20 | Else 21 | strLine = strLine & " " & strArg 22 | End If 23 | Else 24 | strLine = strLine & " " & strArg 25 | End If 26 | End If 27 | Next 28 | ' WScript.Echo strLine 29 | intReturn = WshShell.Run(strLine, 0, false) 30 | WScript.Quit(intReturn) 31 | -------------------------------------------------------------------------------- /resources/vbs/StartHiddenWait.vbs: -------------------------------------------------------------------------------- 1 | ' this script launch a an external program 2 | Set WshShell = WScript.CreateObject("WScript.Shell") 3 | Set filesys = CreateObject("Scripting.FileSystemObject") 4 | Set objArgs = Wscript.Arguments 5 | For Each strArg in objArgs 6 | If (strLine = "") Then 7 | If filesys.FileExists(strArg) Then 8 | WshShell.CurrentDirectory = filesys.GetParentFolderName(strArg) 9 | Else 10 | MsgBox "ERROR : " & strArg & " does not exist", 4112, "CEMU's BatchFw" 11 | End If 12 | strLine = """" & strArg & """" 13 | Else 14 | strLine = strLine & " """ & strArg & """" 15 | End If 16 | Next 17 | intReturn = WshShell.Run(strLine, 0, true) 18 | WScript.Quit(intReturn) 19 | -------------------------------------------------------------------------------- /resources/vbs/StartMaximized.vbs: -------------------------------------------------------------------------------- 1 | ' this script launch a an external program 2 | Set WshShell = WScript.CreateObject("WScript.Shell") 3 | Set filesys = CreateObject("Scripting.FileSystemObject") 4 | Set objArgs = Wscript.Arguments 5 | For Each strArg in objArgs 6 | If (strLine = "") Then 7 | If filesys.FileExists(strArg) Then 8 | WshShell.CurrentDirectory = filesys.GetParentFolderName(strArg) 9 | Else 10 | MsgBox "ERROR : " & strArg & " does not exist", 4112, "CEMU's BatchFw" 11 | End If 12 | strLine = """" & strArg & """" 13 | Else 14 | strLine = strLine & " """ & strArg & """" 15 | End If 16 | Next 17 | intReturn = WshShell.Run(strLine, 3, false) 18 | WScript.Quit(intReturn) 19 | -------------------------------------------------------------------------------- /resources/vbs/StartMaximizedWait.vbs: -------------------------------------------------------------------------------- 1 | ' this script launch a an external program 2 | Set WshShell = WScript.CreateObject("WScript.Shell") 3 | Set filesys = CreateObject("Scripting.FileSystemObject") 4 | Set objArgs = Wscript.Arguments 5 | For Each strArg in objArgs 6 | If (strLine = "") Then 7 | If filesys.FileExists(strArg) Then 8 | WshShell.CurrentDirectory = filesys.GetParentFolderName(strArg) 9 | Else 10 | MsgBox "ERROR : " & strArg & " does not exist", 4112, "CEMU's BatchFw" 11 | End If 12 | strLine = """" & strArg & """" 13 | Else 14 | strLine = strLine & " """ & strArg & """" 15 | End If 16 | Next 17 | intReturn = WshShell.Run(strLine, 3, true) 18 | WScript.Quit(intReturn) 19 | -------------------------------------------------------------------------------- /resources/vbs/StartMinimized.vbs: -------------------------------------------------------------------------------- 1 | ' this script launch a an external program 2 | Set WshShell = WScript.CreateObject("WScript.Shell") 3 | Set filesys = CreateObject("Scripting.FileSystemObject") 4 | Set objArgs = Wscript.Arguments 5 | For Each strArg in objArgs 6 | If (strLine = "") Then 7 | If filesys.FileExists(strArg) Then 8 | WshShell.CurrentDirectory = filesys.GetParentFolderName(strArg) 9 | Else 10 | MsgBox "ERROR : " & strArg & " does not exist", 4112, "CEMU's BatchFw" 11 | End If 12 | strLine = """" & strArg & """" 13 | Else 14 | strLine = strLine & " """ & strArg & """" 15 | End If 16 | Next 17 | intReturn = WshShell.Run(strLine, 2, false) 18 | WScript.Quit(intReturn) 19 | -------------------------------------------------------------------------------- /resources/vbs/StartMinimizedWait.vbs: -------------------------------------------------------------------------------- 1 | ' this script launch a an external program 2 | Set WshShell = WScript.CreateObject("WScript.Shell") 3 | Set filesys = CreateObject("Scripting.FileSystemObject") 4 | Set objArgs = Wscript.Arguments 5 | For Each strArg in objArgs 6 | If (strLine = "") Then 7 | If filesys.FileExists(strArg) Then 8 | WshShell.CurrentDirectory = filesys.GetParentFolderName(strArg) 9 | Else 10 | MsgBox "ERROR : " & strArg & " does not exist", 4112, "CEMU's BatchFw" 11 | End If 12 | strLine = """" & strArg & """" 13 | Else 14 | strLine = strLine & " """ & strArg & """" 15 | End If 16 | Next 17 | intReturn = WshShell.Run(strLine, 2, true) 18 | WScript.Quit(intReturn) 19 | -------------------------------------------------------------------------------- /resources/vbs/StartWait.vbs: -------------------------------------------------------------------------------- 1 | ' this script launch a an external program 2 | Set WshShell = WScript.CreateObject("WScript.Shell") 3 | Set filesys = CreateObject("Scripting.FileSystemObject") 4 | Set objArgs = Wscript.Arguments 5 | For Each strArg in objArgs 6 | If (strLine = "") Then 7 | If filesys.FileExists(strArg) Then 8 | WshShell.CurrentDirectory = filesys.GetParentFolderName(strArg) 9 | Else 10 | MsgBox "ERROR : " & strArg & " does not exist", 4112, "CEMU's BatchFw" 11 | End If 12 | strLine = """" & strArg & """" 13 | Else 14 | strLine = strLine & " """ & strArg & """" 15 | End If 16 | Next 17 | intReturn = WshShell.Run(strLine, 1, true) 18 | WScript.Quit(intReturn) 19 | -------------------------------------------------------------------------------- /resources/winSCP/WinSCP.com: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/winSCP/WinSCP.com -------------------------------------------------------------------------------- /resources/winSCP/WinSCP.exe: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/winSCP/WinSCP.exe -------------------------------------------------------------------------------- /resources/xml.exe: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/resources/xml.exe -------------------------------------------------------------------------------- /resources/xml.txt: -------------------------------------------------------------------------------- 1 | XMLStarlet Toolkit: Edit XML document(s) 2 | Usage: xml ed {} [ ... ] 3 | where 4 | - global options for editing 5 | - input XML document file name/uri (stdin otherwise) 6 | 7 | are: 8 | -P, or -S - preserve whitespace nodes. 9 | (or --pf, --ps) Note that space between attributes is not preserved 10 | -O (or --omit-decl) - omit XML declaration () 11 | -L (or --inplace) - edit file inplace 12 | -N = - predefine namespaces (name without 'xmlns:') 13 | ex: xsql=urn:oracle-xsql 14 | Multiple -N options are allowed. 15 | -N options must be last global options. 16 | --net - allow network access 17 | --help or -h - display help 18 | 19 | where 20 | -d or --delete 21 | --var 22 | -i or --insert -t (--type) elem|text|attr -n [-v (--value) ] 23 | -a or --append -t (--type) elem|text|attr -n [-v (--value) ] 24 | -s or --subnode -t (--type) elem|text|attr -n [-v (--value) ] 25 | -m or --move 26 | -r or --rename -v 27 | -u or --update -v (--value) 28 | -x (--expr) 29 | 30 | XMLStarlet is a command line toolkit to query/edit/check/transform 31 | XML documents (for more information see http://xmlstar.sourceforge.net/) 32 | 33 | xml sel -t -c "//AccountId/text()" !file! 34 | 35 | xml fo -t !file! 36 | 37 | xml ed -s "//AccountId" -t elem -n "Acc" -v "value" !file! 38 | xml ed -a "//AccountId" -t elem -n "Acc" -v "value" !file! 39 | xml ed -i "//AccountId" -t elem -n "Acc" -v "value" !file! 40 | xml ed -u "//AccountId" -v "value" !file! 41 | xml ed -d "//AccountId" !file! 42 | 43 | -------------------------------------------------------------------------------- /tools/backupInGameSaves.bat: -------------------------------------------------------------------------------- 1 | @echo off 2 | setlocal EnableExtensions 3 | REM : ------------------------------------------------------------------ 4 | REM : main 5 | 6 | 7 | setlocal EnableDelayedExpansion 8 | 9 | color 4F 10 | 11 | set "THIS_SCRIPT=%~0" 12 | 13 | REM : checking THIS_SCRIPT path 14 | call:checkPathForDos "!THIS_SCRIPT!" > NUL 2>&1 15 | set /A "cr=!ERRORLEVEL!" 16 | if !cr! NEQ 0 ( 17 | echo ERROR^: Remove DOS reserved characters from the path "!THIS_SCRIPT!" ^(such as ^&^, %% or ^^!^)^, cr=!cr! 18 | pause 19 | exit 1 20 | ) 21 | 22 | REM : directory of this script 23 | set "SCRIPT_FOLDER="%~dp0"" && set "BFW_TOOLS_PATH=!SCRIPT_FOLDER:\"="!" 24 | 25 | for %%a in (!BFW_TOOLS_PATH!) do set "parentFolder="%%~dpa"" 26 | set "BFW_PATH=!parentFolder:~0,-2!"" 27 | for %%a in (!BFW_PATH!) do set "parentFolder="%%~dpa"" 28 | for %%a in (!BFW_PATH!) do set "drive=%%~da" 29 | set "GAMES_FOLDER=!parentFolder!" 30 | if not [!GAMES_FOLDER!] == ["!drive!\"] set "GAMES_FOLDER=!parentFolder:~0,-2!"" 31 | 32 | 33 | set "BFW_RESOURCES_PATH="!BFW_PATH:"=!\resources"" 34 | set "BFW_LOGS="!BFW_PATH:"=!\logs"" 35 | 36 | set "StartHiddenWait="!BFW_RESOURCES_PATH:"=!\vbs\StartHiddenWait.vbs"" 37 | 38 | set "logFile="!BFW_LOGS:"=!\Host_!USERDOMAIN!.log"" 39 | 40 | REM : checking GAMES_FOLDER folder 41 | call:checkPathForDos !GAMES_FOLDER! 42 | 43 | REM : set current char codeset 44 | call:setCharSet 45 | 46 | REM : cd to GAMES_FOLDER 47 | pushd !GAMES_FOLDER! 48 | 49 | REM : RAR.exe path 50 | set "rarExe="!BFW_PATH:"=!\resources\rar.exe"" 51 | 52 | REM : checking arguments 53 | set /A "nbArgs=0" 54 | :continue 55 | if "%~1"=="" goto:end 56 | set "args[%nbArgs%]="%~1"" 57 | set /A "nbArgs +=1" 58 | shift 59 | goto:continue 60 | :end 61 | 62 | if %nbArgs% NEQ 5 ( 63 | echo ERROR on arguments passed^! 64 | echo SYNTAX^: %THIS_FILE% GAME_FOLDER_PATH MLC01_FOLDER_PATH user endTitleId slotNumber 65 | echo given {%*} 66 | pause 67 | exit /b 99 68 | ) 69 | 70 | REM : get and check MLC01_FOLDER_PATH 71 | set "GAME_FOLDER_PATH=!args[0]!" 72 | if not exist !GAME_FOLDER_PATH! ( 73 | echo ERROR^: game^'s folder !GAME_FOLDER_PATH! does not exist^! 74 | pause 75 | exit /b 1 76 | ) 77 | 78 | REM : get and check MLC01_FOLDER_PATH 79 | set "MLC01_FOLDER_PATH=!args[1]!" 80 | if not exist !MLC01_FOLDER_PATH! ( 81 | echo ERROR^: mlc01 folder !MLC01_FOLDER_PATH! does not exist^! 82 | pause 83 | exit /b 3 84 | ) 85 | 86 | set "user=!args[2]!" 87 | set "currentUser=!user:"=!" 88 | 89 | set "endTitleId=!args[3]!" 90 | set "endTitleId=!endTitleId:"=!" 91 | set "endTitleId=!endTitleId: =!" 92 | 93 | set "slotNumberStr=!args[4]!" 94 | set "slotNumberStr=!slotNumberStr:"=!" 95 | set /A "slotNumber=!slotNumberStr: =!" 96 | 97 | REM : basename of GAME FOLDER PATH (to get GAME_TITLE) 98 | for /F "delims=~" %%i in (!GAME_FOLDER_PATH!) do set "GAME_TITLE=%%~nxi" 99 | 100 | set "inGameSavesFolder="!GAME_FOLDER_PATH:"=!\Cemu\inGameSaves"" 101 | if not exist !inGameSavesFolder! mkdir !inGameSavesFolder! > NUL 2>&1 102 | 103 | pushd !inGameSavesFolder! 104 | set "rarFile="!GAME_FOLDER_PATH:"=!\Cemu\inGameSaves\!GAME_TITLE!_!currentUser!.rar"" 105 | 106 | if !slotNumber! NEQ 0 set "rarFile="!GAME_FOLDER_PATH:"=!\Cemu\inGameSaves\!GAME_TITLE!_!currentUser!_slot!slotNumber!.rar"" 107 | 108 | REM : if exists rename-it the time of the compression 109 | set "waitFile=!rarFile:.rar=.bfw_wait!" 110 | if exist !waitFile! del /F !waitFile! > NUL 2>&1 111 | 112 | if exist !rarFile! move /Y !rarFile! !waitFile! > NUL 2>&1 113 | 114 | set usrSaveFolder="!MLC01_FOLDER_PATH:"=!\usr\save" 115 | for /F "delims=~" %%i in ('dir /b /o:n /a:d !usrSaveFolder! 2^>NUL') do ( 116 | call:compress "%%i" cr 117 | ) 118 | REM : compression ok? finished 119 | if exist !rarFile! del /F !waitFile! > NUL 2>&1 120 | 121 | if %nbArgs% EQU 0 endlocal 122 | exit /b 0 123 | 124 | goto:eof 125 | 126 | REM : ------------------------------------------------------------------ 127 | 128 | REM : ------------------------------------------------------------------ 129 | REM : functions 130 | 131 | :compress 132 | set "sf="!MLC01_FOLDER_PATH:"=!\usr\save\%~1\%endTitleId%"" 133 | 134 | REM : check if a user folder exist 135 | set "userFolder="!sf:"=!\user" 136 | if not exist !userFolder! goto:eof 137 | 138 | if exist !sf! ( 139 | wscript /nologo !StartHiddenWait! !rarExe! u -ed -ap"mlc01\usr\save\%~1" -ep1 -r -inul -w!BFW_LOGS! !rarFile! !sf! > NUL 2>&1 140 | set "%1=!ERRORLEVEL!" 141 | ) 142 | 143 | goto:eof 144 | REM : ------------------------------------------------------------------ 145 | 146 | REM : function to get and set char set code for current host 147 | :setCharSet 148 | 149 | REM : get charset code for current HOST 150 | set "CHARSET=NOT_FOUND" 151 | for /F "tokens=2 delims=~=" %%f in ('wmic os get codeset /value 2^>NUL ^| find "="') do set "CHARSET=%%f" 152 | 153 | if ["%CHARSET%"] == ["NOT_FOUND"] ( 154 | echo Host char codeSet not found in %0 ^? 155 | pause 156 | exit /b 9 157 | ) 158 | REM : set char code set, output to host log file 159 | 160 | chcp %CHARSET% > NUL 2>&1 161 | call:log2HostFile "charCodeSet=%CHARSET%" 162 | 163 | goto:eof 164 | REM : ------------------------------------------------------------------ 165 | 166 | :checkPathForDos 167 | 168 | set "toCheck=%1" 169 | 170 | REM : if implicit expansion failed (when calling this script) 171 | if ["!toCheck!"] == [""] ( 172 | echo Remove special characters from %1 ^(such as ^&, ^(,^), ^!^)^, exiting 13 173 | exit /b 13 174 | ) 175 | 176 | REM : try to resolve 177 | if not exist !toCheck! ( 178 | echo This path ^(!toCheck!^) is not compatible with DOS^. Remove special characters from this path ^(such as ^&,^(,^),^!^)^, exiting 11 179 | exit /b 11 180 | ) 181 | 182 | REM : try to list 183 | dir !toCheck! > NUL 2>&1 184 | if !ERRORLEVEL! NEQ 0 ( 185 | echo This path ^(!toCheck!^) is not compatible with DOS^. Remove special characters from this path ^(such as ^&,^(,^),^!^)^, exiting 12 186 | exit /b 12 187 | ) 188 | 189 | exit /b 0 190 | goto:eof 191 | REM : ------------------------------------------------------------------ 192 | 193 | REM : function to log info for current host 194 | :log2HostFile 195 | REM : arg1 = msg 196 | set "msg=%~1" 197 | 198 | if not exist !logFile! ( 199 | set "logFolder="!BFW_PATH:"=!\logs"" 200 | if not exist !logFolder! mkdir !logFolder! > NUL 2>&1 201 | goto:logMsg2HostFile 202 | ) 203 | REM : check if the message is not already entierely present 204 | for /F %%i in ('type !logFile! ^| find /I "!msg!"') do goto:eof 205 | :logMsg2HostFile 206 | echo !msg!>> !logFile! 207 | 208 | goto:eof 209 | REM : ------------------------------------------------------------------ -------------------------------------------------------------------------------- /tools/convertWiiuFiles.bat: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/tools/convertWiiuFiles.bat -------------------------------------------------------------------------------- /tools/createExtraGraphicPacks.bat: -------------------------------------------------------------------------------- 1 | @echo off 2 | setlocal EnableExtensions 3 | REM : ------------------------------------------------------------------ 4 | REM : main 5 | 6 | setlocal EnableDelayedExpansion 7 | 8 | REM color 4F 9 | set "THIS_SCRIPT=%~0" 10 | 11 | REM : directory of this script 12 | set "SCRIPT_FOLDER="%~dp0"" && set "BFW_TOOLS_PATH=!SCRIPT_FOLDER:\"="!" 13 | 14 | for %%a in (!BFW_TOOLS_PATH!) do set "parentFolder="%%~dpa"" 15 | set "BFW_PATH=!parentFolder:~0,-2!"" 16 | for %%a in (!BFW_PATH!) do set "parentFolder="%%~dpa"" 17 | for %%a in (!BFW_PATH!) do set "drive=%%~da" 18 | set "GAMES_FOLDER=!parentFolder!" 19 | if not [!GAMES_FOLDER!] == ["!drive!\"] set "GAMES_FOLDER=!parentFolder:~0,-2!"" 20 | 21 | set "BFW_RESOURCES_PATH="!BFW_PATH:"=!\resources"" 22 | set "wiiTitlesDataBase="!BFW_RESOURCES_PATH:"=!\WiiU-Titles-Library.csv"" 23 | 24 | set "BFW_LOGS="!BFW_PATH:"=!\logs"" 25 | set "logFile="!BFW_LOGS:"=!\Host_!USERDOMAIN!.log"" 26 | set "glogFile="!BFW_LOGS:"=!\gamesLibrary.log"" 27 | 28 | set "cgpLogFile="!BFW_LOGS:"=!\createExtraGraphicPacks.log"" 29 | 30 | set "completeLastGraphicPacks="!BFW_TOOLS_PATH:"=!\completeLastGraphicPacks.bat"" 31 | set "completeV4="!BFW_TOOLS_PATH:"=!\completeV4GraphicPacks.bat"" 32 | set "completeV2="!BFW_TOOLS_PATH:"=!\completeV2GraphicPacks.bat"" 33 | 34 | REM : set current char codeset 35 | call:setCharSet 36 | 37 | 38 | REM : checking arguments 39 | set /A "nbArgs=0" 40 | :continue 41 | if "%~1"=="" goto:end 42 | set "args[%nbArgs%]="%~1"" 43 | set /A "nbArgs +=1" 44 | shift 45 | goto:continue 46 | :end 47 | 48 | REM : get current date 49 | for /F "usebackq tokens=1,2 delims=~=" %%i in (`wmic os get LocalDateTime /VALUE 2^>NUL`) do if '.%%i.'=='.LocalDateTime.' set "ldt=%%j" 50 | set "ldt=%ldt:~0,4%-%ldt:~4,2%-%ldt:~6,2%_%ldt:~8,2%-%ldt:~10,2%-%ldt:~12,6%" 51 | REM : starting DATE 52 | set "startingDate=%ldt%" 53 | echo. > !cgpLogFile! 54 | 55 | if %nbArgs% NEQ 2 ( 56 | echo ERROR ^: on arguments passed ^! 57 | echo SYNTAXE ^: "!THIS_SCRIPT!" RULES_FILE TITLE_ID>> !cgpLogFile! 58 | echo SYNTAXE ^: "!THIS_SCRIPT!" RULES_FILE TITLE_ID 59 | echo given {%*} >> !cgpLogFile! 60 | echo given {%*} 61 | 62 | exit /b 99 63 | ) 64 | 65 | set "rulesFile=!args[0]!" 66 | set "titleId=!args[1]!" 67 | set "titleId=!titleId:"=!" 68 | set "titleId=!titleId: =!" 69 | 70 | REM : Get the version of the GFX pack 71 | set "vGfxPackStr=NOT_FOUND" 72 | for /F "delims=~= tokens=2" %%i in ('type !rulesFile! ^| find /I "Version"') do set "vGfxPackStr=%%i" 73 | set "vGfxPackStr=%vGfxPackStr: =%" 74 | if ["!vGfxPackStr!"] == ["NOT_FOUND"] ( 75 | echo ERROR : version was not found in !rulesFile! >> !cgpLogFile! 76 | echo ERROR : version was not found in !rulesFile! 77 | goto:eof 78 | ) 79 | set /A "vGfxPack=!vGfxPackStr!" 80 | 81 | 82 | echo Completing V!vGfxPack! pack^.^.^. >> !cgpLogFile! 83 | echo Completing V!vGfxPack! pack^.^.^. 84 | 85 | set "rulesFolder=!rulesFile:\rules.txt=!" 86 | 87 | if !vGfxPack! GTR 2 goto:V4packs 88 | REM : V2 packs 89 | echo !completeV2! !rulesFile! >> !cgpLogFile! 90 | echo !completeV2! !rulesFile! 91 | 92 | REM : for V2 packs, as new folders are created and linked afterward in updateGamesGraphicPacks.bat 93 | REM : do not wait 94 | call !completeV2! !rulesFile! 95 | 96 | for /F "delims=~" %%i in (!rulesFolder!) do set "gpNameFolder=%%~nxi" 97 | set "GAME_TITLE=!gpNameFolder:_%resX2%p=!" 98 | 99 | REM : update !glogFile! (log2GamesLibraryFile does not add a already present message in !glogFile!) 100 | set "msg="!GAME_TITLE! [%titleId%] graphic packs versionV2=completed"" 101 | call:log2GamesLibraryFile !msg! 102 | 103 | goto:endMain 104 | 105 | :V4packs 106 | if !vGfxPack! GEQ 6 goto:V6packs 107 | 108 | REM : V4 packs 109 | echo !completeV4! !rulesFile! >> !cgpLogFile! 110 | echo !completeV4! !rulesFile! 111 | 112 | call !completeV4! !rulesFile! 113 | 114 | set "GAME_TITLE=!gpNameFolder:_resolution=!" 115 | 116 | REM : update !glogFile! (log2GamesLibraryFile does not add a already present message in !glogFile!) 117 | set "msg="!GAME_TITLE! [%titleId%] graphic packs versionV4=completed"" 118 | call:log2GamesLibraryFile !msg! 119 | 120 | goto:endMain 121 | 122 | :V6packs 123 | REM : V6 packs 124 | echo !completeLastGraphicPacks! !rulesFile! >> !cgpLogFile! 125 | echo !completeLastGraphicPacks! !rulesFile! 126 | 127 | call !completeLastGraphicPacks! !rulesFile! 128 | 129 | REM : !glogFile! is updated in updateGamesGraphicPacks 130 | 131 | :endMain 132 | REM : ending DATE 133 | for /F "usebackq tokens=1,2 delims=~=" %%i in (`wmic os get LocalDateTime /VALUE 2^>NUL`) do if '.%%i.'=='.LocalDateTime.' set "ldt=%%j" 134 | set "ldt=%ldt:~0,4%-%ldt:~4,2%-%ldt:~6,2%_%ldt:~8,2%-%ldt:~10,2%-%ldt:~12,6%" 135 | set "endingDate=%ldt%" 136 | REM : starting DATE 137 | 138 | echo ========================================================= >> !cgpLogFile! 139 | echo ========================================================= 140 | 141 | echo starting date = %startingDate% >> !cgpLogFile! 142 | echo starting date = %startingDate% 143 | echo ending date = %endingDate% >> !cgpLogFile! 144 | echo ending date = %endingDate% 145 | 146 | if %nbArgs% EQU 0 endlocal && pause 147 | exit /b 0 148 | 149 | goto:eof 150 | 151 | REM : ------------------------------------------------------------------ 152 | 153 | REM : ------------------------------------------------------------------ 154 | REM : functions 155 | 156 | REM : function to log info for current host 157 | :log2GamesLibraryFile 158 | REM : arg1 = msg 159 | set "msg=%~1" 160 | 161 | if not exist !glogFile! ( 162 | set "logFolder="!BFW_PATH:"=!\logs"" 163 | if not exist !logFolder! mkdir !logFolder! > NUL 2>&1 164 | goto:logMsg2GamesLibraryFile 165 | ) 166 | 167 | REM : check if the message is not already entierely present 168 | for /F %%i in ('type !glogFile! ^| find /I "!msg!" 2^>NUL') do goto:eof 169 | 170 | :logMsg2GamesLibraryFile 171 | echo !msg! >> !glogFile! 172 | REM : sorting the log 173 | set "gLogFileTmp="!glogFile:"=!.bfw_tmp"" 174 | type !glogFile! | sort > !gLogFileTmp! 175 | del /F /S !glogFile! > NUL 2>&1 176 | move /Y !gLogFileTmp! !glogFile! > NUL 2>&1 177 | 178 | goto:eof 179 | REM : ------------------------------------------------------------------ 180 | 181 | REM : function to get and set char set code for current host 182 | :setCharSet 183 | 184 | REM : get charset code for current HOST 185 | set "CHARSET=NOT_FOUND" 186 | for /F "tokens=2 delims=~=" %%f in ('wmic os get codeset /value 2^>NUL ^| find "="') do set "CHARSET=%%f" 187 | 188 | if ["%CHARSET%"] == ["NOT_FOUND"] ( 189 | echo Host char codeSet not found in %0 ^? 190 | exit /b 9 191 | ) 192 | REM : set char code set, output to host log file 193 | 194 | chcp %CHARSET% > NUL 2>&1 195 | call:log2HostFile "charCodeSet=%CHARSET%" 196 | 197 | goto:eof 198 | REM : ------------------------------------------------------------------ 199 | 200 | REM : function to log info for current host 201 | :log2HostFile 202 | REM : arg1 = msg 203 | set "msg=%~1" 204 | 205 | if not exist !logFile! ( 206 | set "logFolder="!BFW_PATH:"=!\logs"" 207 | if not exist !logFolder! mkdir !logFolder! > NUL 2>&1 208 | goto:logMsg2HostFile 209 | ) 210 | REM : check if the message is not already entierely present 211 | for /F %%i in ('type !logFile! ^| find /I "!msg!"') do goto:eof 212 | :logMsg2HostFile 213 | echo !msg!>> !logFile! 214 | 215 | goto:eof 216 | REM : ------------------------------------------------------------------ 217 | -------------------------------------------------------------------------------- /tools/createWiiuSDcard.bat: -------------------------------------------------------------------------------- 1 | @echo off 2 | setlocal EnableExtensions 3 | REM : ------------------------------------------------------------------ 4 | REM : main 5 | 6 | setlocal EnableDelayedExpansion 7 | 8 | color 4F 9 | 10 | set "THIS_SCRIPT=%~0" 11 | REM : checking THIS_SCRIPT path 12 | call:checkPathForDos "!THIS_SCRIPT!" > NUL 2>&1 13 | set /A "cr=!ERRORLEVEL!" 14 | if !cr! NEQ 0 ( 15 | echo ERROR^: Remove DOS reserved characters from the path "!THIS_SCRIPT!" ^(such as ^&^, %% or ^^!^)^, cr=!cr! 16 | pause 17 | exit 1 18 | ) 19 | 20 | REM : directory of this script 21 | set "SCRIPT_FOLDER="%~dp0"" && set "BFW_TOOLS_PATH=!SCRIPT_FOLDER:\"="!" 22 | 23 | for %%a in (!BFW_TOOLS_PATH!) do set "parentFolder="%%~dpa"" 24 | set "BFW_PATH=!parentFolder:~0,-2!"" 25 | for %%a in (!BFW_PATH!) do set "parentFolder="%%~dpa"" 26 | for %%a in (!BFW_PATH!) do set "drive=%%~da" 27 | set "GAMES_FOLDER=!parentFolder!" 28 | if not [!GAMES_FOLDER!] == ["!drive!\"] set "GAMES_FOLDER=!parentFolder:~0,-2!"" 29 | 30 | set "BFW_RESOURCES_PATH="!BFW_PATH:"=!\resources"" 31 | set "cmdOw="!BFW_RESOURCES_PATH:"=!\cmdOw.exe"" 32 | !cmdOw! @ /MAX > NUL 2>&1 33 | 34 | set "ffat32="!BFW_RESOURCES_PATH:"=!\fat32format.exe"" 35 | set "rarExe="!BFW_PATH:"=!\resources\rar.exe"" 36 | 37 | set "StartHiddenWait="!BFW_RESOURCES_PATH:"=!\vbs\StartHiddenWait.vbs"" 38 | set "browseFolder="!BFW_RESOURCES_PATH:"=!\vbs\BrowseFolderDialog.vbs"" 39 | 40 | set "BFW_LOGS="!BFW_PATH:"=!\logs"" 41 | set "logFile="!BFW_LOGS:"=!\Host_!USERDOMAIN!.log"" 42 | 43 | REM : set current char codeset 44 | call:setCharSet 45 | cls 46 | 47 | echo ========================================================= 48 | echo Prepare a SDcard for the Wii-U 49 | echo ========================================================= 50 | echo. 51 | echo - format your device in FAT32 (32K clusters size) 52 | echo - install ^: 53 | echo ^* HBL ^(HomeBrew Launcher^) 54 | echo ^* appStore ^(HomeBrew AppStore^) 55 | echo ^* DDD ^(WiiU Disk itle Dumper^) 56 | echo ^* MOCHA ^(MOCHA CFW^) 57 | echo ^* WiiU FTP Server 58 | echo ^* loadiine_gx2_y_mod ^(to launch DDD dumps^) 59 | echo ^* nanddumper ^(to dump your NAND and get online files^) 60 | echo ^* dumpling ^(dump your games^) 61 | echo ^* sigpatcher2sysmenu ^(DLC patch with non permanent CFW^) 62 | echo ^* wup_installer_gx2 ^(installer for WUP format^) 63 | echo. 64 | echo Once plugged in your Wii-U^, open the internet browser 65 | echo and enter the following adress ^: http^:^/^/wiiuexploit^.xyz 66 | echo ^(you might add this URL to your favorites^) 67 | echo. 68 | echo if your wiiu is connected to internet^, you can use 69 | echo appStore to update^/install other apps. 70 | echo. 71 | echo ========================================================= 72 | echo. 73 | echo Close ALL windows explorer instances^, before continue 74 | echo. 75 | pause 76 | 77 | :askDrive 78 | set "SDCARD="NONE"" 79 | for /F %%b in ('cscript /nologo !browseFolder! "Select the drive of your SDCard"') do set "folder=%%b" && set "SDCARD=!folder:?= !" 80 | if [!SDCARD!] == ["NONE"] ( 81 | choice /C yn /N /M "No item selected, do you wish to cancel (y, n)? : " 82 | if !ERRORLEVEL! EQU 1 timeout /T 4 > NUL 2>&1 && exit 75 83 | goto:askDrive 84 | ) 85 | 86 | for %%a in (!SDCARD!) do set "SDCARD=%%~da" 87 | :formatDrive 88 | REM : format %SDCARD% with fat32format.exe 89 | !ffat32! -c64 %SDCARD% 90 | if !ERRORLEVEL! NEQ 0 goto:formatDrive 91 | echo. 92 | echo --------------------------------------------------------- 93 | echo Installing content^.^.^. 94 | REM : install content 95 | set "sdCardContent="!BFW_RESOURCES_PATH:"=!\WiiuSDcard.rar"" 96 | 97 | wscript /nologo !StartHiddenWait! !rarExe! x -o+ -inul -w!BFW_LOGS! !sdCardContent! !SDCARD! > NUL 2>&1 98 | echo done 99 | echo ========================================================= 100 | 101 | pause 102 | 103 | exit /b 0 104 | 105 | goto:eof 106 | REM : ------------------------------------------------------------------ 107 | 108 | 109 | 110 | REM : ------------------------------------------------------------------ 111 | REM : functions 112 | 113 | :checkPathForDos 114 | 115 | set "toCheck=%1" 116 | 117 | REM : if implicit expansion failed (when calling this script) 118 | if ["!toCheck!"] == [""] ( 119 | echo Remove specials characters from %1 ^(such as ^&,^(,^),^!^)^, exiting 13 120 | exit /b 13 121 | ) 122 | 123 | REM : try to resolve 124 | if not exist !toCheck! ( 125 | echo This path ^(!toCheck!^) is not compatible with DOS^. Remove specials characters from this path ^(such as ^&,^(,^),^!^)^, exiting 11 126 | exit /b 11 127 | ) 128 | 129 | REM : try to list 130 | dir !toCheck! > NUL 2>&1 131 | if !ERRORLEVEL! NEQ 0 ( 132 | echo This path ^(!toCheck!^) is not compatible with DOS^. Remove specials characters from this path ^(such as ^&,^(,^),^!^)^, exiting 12 133 | exit /b 12 134 | ) 135 | 136 | exit /b 0 137 | goto:eof 138 | REM : ------------------------------------------------------------------ 139 | 140 | REM : function to get and set char set code for current host 141 | :setCharSet 142 | 143 | REM : get charset code for current HOST 144 | set "CHARSET=NOT_FOUND" 145 | for /F "tokens=2 delims=~=" %%f in ('wmic os get codeset /value 2^>NUL ^| find "="') do set "CHARSET=%%f" 146 | 147 | if ["%CHARSET%"] == ["NOT_FOUND"] ( 148 | echo Host char codeSet not found in %0 ^? 149 | timeout /t 8 > NUL 2>&1 150 | exit /b 9 151 | ) 152 | REM : set char code set, output to host log file 153 | 154 | chcp %CHARSET% > NUL 2>&1 155 | 156 | REM : get locale for current HOST 157 | set "L0CALE_CODE=NOT_FOUND" 158 | for /F "tokens=2 delims=~=" %%f in ('wmic path Win32_OperatingSystem get Locale /value 2^>NUL ^| find "="') do set "L0CALE_CODE=%%f" 159 | 160 | goto:eof 161 | REM : ------------------------------------------------------------------ 162 | -------------------------------------------------------------------------------- /tools/deleteMyGpuCache.bat: -------------------------------------------------------------------------------- 1 | @echo off 2 | setlocal EnableExtensions 3 | REM : ------------------------------------------------------------------ 4 | REM : main 5 | 6 | setlocal EnableDelayedExpansion 7 | 8 | color 4F 9 | 10 | set "THIS_SCRIPT=%~0" 11 | 12 | REM : checking THIS_SCRIPT path 13 | call:checkPathForDos "!THIS_SCRIPT!" > NUL 2>&1 14 | set /A "cr=!ERRORLEVEL!" 15 | if !cr! NEQ 0 ( 16 | echo ERROR ^: Remove DOS reserved characters from the path "!THIS_SCRIPT!" ^(such as ^&^, %% or ^^!^)^, cr=!cr! 17 | pause 18 | exit 1 19 | ) 20 | 21 | REM : directory of this script 22 | set "SCRIPT_FOLDER="%~dp0"" && set "BFW_TOOLS_PATH=!SCRIPT_FOLDER:\"="!" 23 | 24 | for %%a in (!BFW_TOOLS_PATH!) do set "basename="%%~dpa"" 25 | set "BFW_PATH=!basename:~0,-2!"" 26 | 27 | set "logFile="!BFW_PATH:"=!\logs\Host_!USERDOMAIN!.log"" 28 | 29 | REM : set current char codeset 30 | call:setCharSet 31 | 32 | REM : search if launchGame.bat is not already running 33 | set /A "nbI=0" 34 | for /F "delims=~=" %%f in ('wmic process get Commandline 2^>NUL ^| find /I "cmd.exe" ^| find /I "launchGame.bat" ^| find /I /V "find" /C') do set /A "nbI=%%f" 35 | if %nbI% GEQ 1 ( 36 | echo ERROR^: launchGame^.bat is already^/still running^! If needed^, use ^'Wii-U Games^\BatchFw^\Kill BatchFw Processes^.lnk^'^. Aborting^! 37 | wmic process get Commandline 2>NUL | find /I "cmd.exe" | find /I "launchGame.bat" | find /I /V "find" 38 | pause 39 | exit 100 40 | ) 41 | 42 | REM : cd to BFW_TOOLS_PATH 43 | pushd !BFW_TOOLS_PATH! 44 | 45 | REM : get current date 46 | for /F "usebackq tokens=1,2 delims=~=" %%i in (`wmic os get LocalDateTime /VALUE 2^>NUL`) do if '.%%i.'=='.LocalDateTime.' set "ldt=%%j" 47 | set "ldt=%ldt:~0,4%-%ldt:~4,2%-%ldt:~6,2%_%ldt:~8,2%-%ldt:~10,2%-%ldt:~12,6%" 48 | set "DATE=%ldt%" 49 | 50 | REM : search your current GLCache 51 | REM : check last path saved in log file 52 | 53 | REM : search in logFile, getting only the last occurence 54 | 55 | set "OPENGL_CACHE="NOT_FOUND"" 56 | for /F "tokens=2 delims=~=" %%i in ('type !logFile! ^| find /I "OPENGL_CACHE" 2^>NUL') do set "OPENGL_CACHE=%%i" 57 | 58 | if not [!OPENGL_CACHE!] == ["NOT_FOUND"] if exist !OPENGL_CACHE! goto:glCacheFound 59 | 60 | REM : else search it 61 | pushd "%LOCALAPPDATA%" 62 | set "cache="NOT_FOUND"" 63 | for /F "delims=~" %%x in ('dir /b /o:n /a:d /s GLCache 2^>NUL') do set "cache="%%x"" 64 | if [!cache!] == ["NOT_FOUND"] pushd "%APPDATA%" && for /F "delims=~" %%x in ('dir /b /o:n /a:d /s GLCache 2^>NUL') do set "cache="%%x"" 65 | if not [!cache!] == ["NOT_FOUND"] set "OPENGL_CACHE=!cache!" 66 | pushd !BFW_TOOLS_PATH! 67 | 68 | if [!OPENGL_CACHE!] == ["NOT_FOUND"] ( 69 | echo Unable to find your GPU GLCache folder ^? cancelling 70 | goto:eof 71 | ) 72 | 73 | REM : save path to log file 74 | set "msg="OPENGL_CACHE=!OPENGL_CACHE:"=!"" 75 | call:log2HostFile !msg! 76 | 77 | REM : openGL cache location 78 | :glCacheFound 79 | choice /C yn /T 4 /D y /N /M "Flush !OPENGL_CACHE:"=! (y/n : yes by default in 4s) ?:" 80 | if %ERRORLEVEL% EQU 2 ( 81 | choice /C y /T 2 /D y /N /M "> Cancelled by user" 82 | goto:cemuInstalls 83 | ) 84 | rmdir /Q /S !OPENGL_CACHE! > NUL 2>&1 85 | mkdir !OPENGL_CACHE! > NUL 2>&1 86 | 87 | echo ^> !OPENGL_CACHE:"=! was cleared ^! 88 | 89 | :cemuInstalls 90 | 91 | 92 | choice /C yn /T 4 /D y /N /M "Clear all shader caches of ALL your CEMU installs (y/n : yes by default in 4s) ?:" 93 | if %ERRORLEVEL% EQU 2 ( 94 | choice /C y /T 2 /D y /N /M "> Cancelled by user" 95 | goto:log 96 | ) 97 | 98 | REM : search in logFile, getting only the last occurence 99 | set "installPath=NONE" 100 | for /F "tokens=2 delims=~=" %%i in ('type !logFile! ^| find "install folder path" 2^>NUL') do ( 101 | 102 | set "installPath="%%i"" 103 | set "GLCache="!installPath:"=!\shaderCache\driver"" 104 | if exist !GLCache! echo ^> Clearing !GLCache! && rmdir /S /Q !GLCache! > NUL 2>&1 105 | set "pcCache="!installPath:"=!\shaderCache\precompiled"" 106 | echo ^> Clearing !pcCache! 107 | for /F "delims=~" %%i in ('dir /B /S !pcCache! 2^>NUL') do del /F "%%i" > NUL 2>&1 108 | ) 109 | 110 | :log 111 | set "msg="!DATE! Shader Caches deleted by !USERNAME!"" 112 | call:log2HostFile !msg! 113 | 114 | timeout /T 3 > NUL 2>&1 115 | 116 | endlocal 117 | exit /b 0 118 | 119 | goto:eof 120 | 121 | REM : ------------------------------------------------------------------ 122 | 123 | 124 | REM : ------------------------------------------------------------------ 125 | REM : functions 126 | 127 | REM : function to get and set char set code for current host 128 | :setCharSet 129 | 130 | REM : get charset code for current HOST 131 | set "CHARSET=NOT_FOUND" 132 | for /F "tokens=2 delims=~=" %%f in ('wmic os get codeset /value 2^>NUL ^| find "="') do set "CHARSET=%%f" 133 | 134 | if ["%CHARSET%"] == ["NOT_FOUND"] ( 135 | echo Host char codeSet not found in %0 ^? 136 | pause 137 | exit /b 9 138 | ) 139 | REM : set char code set, output to host log file 140 | 141 | chcp %CHARSET% > NUL 2>&1 142 | call:log2HostFile "charCodeSet=%CHARSET%" 143 | 144 | goto:eof 145 | REM : ------------------------------------------------------------------ 146 | 147 | :checkPathForDos 148 | 149 | set "toCheck=%1" 150 | 151 | REM : if implicit expansion failed (when calling this script) 152 | if ["!toCheck!"] == [""] ( 153 | echo Remove specials characters from %1 ^(such as ^&,^(,^),^!^)^, exiting 13 154 | exit /b 13 155 | ) 156 | 157 | REM : try to resolve 158 | if not exist !toCheck! ( 159 | echo This path ^(!toCheck!^) is not compatible with DOS^. Remove specials characters from this path ^(such as ^&,^(,^),^!^)^, exiting 11 160 | exit /b 11 161 | ) 162 | 163 | REM : try to list 164 | dir !toCheck! > NUL 2>&1 165 | if !ERRORLEVEL! NEQ 0 ( 166 | echo This path ^(!toCheck!^) is not compatible with DOS^. Remove specials characters from this path ^(such as ^&,^(,^),^!^)^, exiting 12 167 | exit /b 12 168 | ) 169 | 170 | exit /b 0 171 | goto:eof 172 | REM : ------------------------------------------------------------------ 173 | 174 | REM : function to log info for current host 175 | :log2HostFile 176 | REM : arg1 = msg 177 | set "msg=%~1" 178 | 179 | if not exist !logFile! ( 180 | set "logFolder="!BFW_PATH:"=!\logs"" 181 | if not exist !logFolder! mkdir !logFolder! > NUL 2>&1 182 | goto:logMsg2HostFile 183 | ) 184 | REM : check if the message is not already entierely present 185 | for /F %%i in ('type !logFile! ^| find /I "!msg!"') do goto:eof 186 | :logMsg2HostFile 187 | echo !msg!>> !logFile! 188 | 189 | goto:eof 190 | REM : ------------------------------------------------------------------ 191 | -------------------------------------------------------------------------------- /tools/detectAndRenameInvalidPath.bat: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/tools/detectAndRenameInvalidPath.bat -------------------------------------------------------------------------------- /tools/displayProgressBar.bat: -------------------------------------------------------------------------------- 1 | @echo off 2 | setlocal EnableExtensions 3 | REM : ------------------------------------------------------------------ 4 | REM : main 5 | 6 | setlocal EnableDelayedExpansion 7 | 8 | color 4F 9 | 10 | set "THIS_SCRIPT=%~0" 11 | 12 | REM : directory of this script 13 | set "SCRIPT_FOLDER="%~dp0"" && set "BFW_TOOLS_PATH=!SCRIPT_FOLDER:\"="!" 14 | 15 | for %%a in (!BFW_TOOLS_PATH!) do set "parentFolder="%%~dpa"" 16 | set "BFW_PATH=!parentFolder:~0,-2!"" 17 | for %%a in (!BFW_PATH!) do set "parentFolder="%%~dpa"" 18 | for %%a in (!BFW_PATH!) do set "drive=%%~da" 19 | set "GAMES_FOLDER=!parentFolder!" 20 | if not [!GAMES_FOLDER!] == ["!drive!\"] set "GAMES_FOLDER=!parentFolder:~0,-2!"" 21 | 22 | set "BFW_RESOURCES_PATH="!BFW_PATH:"=!\resources"" 23 | 24 | set "logFile="!BFW_PATH:"=!\logs\Host_!USERDOMAIN!.log"" 25 | 26 | REM : set current char codeset 27 | call:setCharSet 28 | 29 | REM : checking arguments 30 | set /A "nbArgs=0" 31 | :continue 32 | if "%~1"=="" goto:end 33 | set "args[%nbArgs%]="%~1"" 34 | set /A "nbArgs +=1" 35 | shift 36 | goto:continue 37 | :end 38 | 39 | if %nbArgs% NEQ 1 ( 40 | echo ERROR ^: on arguments passed ^! 41 | echo SYNTAXE ^: "!THIS_SCRIPT!" ON or OFF 42 | echo given {%*} 43 | pause 44 | exit /b 99 45 | ) 46 | 47 | REM : get mode 48 | set "pbMode=!args[0]!" 49 | 50 | if [!pbMode!] == ["OFF"] ( 51 | REM : clean USE_PROGRESSBAR in host log file 52 | call:cleanHostLogFile USE_PROGRESSBAR 53 | exit /b 0 54 | ) 55 | set "msg="USE_PROGRESSBAR=YES"" 56 | call:log2HostFile !msg! 57 | exit /b 1 58 | 59 | goto:eof 60 | 61 | REM : ------------------------------------------------------------------ 62 | 63 | 64 | REM : ------------------------------------------------------------------ 65 | REM : functions 66 | 67 | :cleanHostLogFile 68 | REM : pattern to ignore in log file 69 | set "pat=%~1" 70 | set "logFileTmp="!logFile:"=!.bfw_tmp"" 71 | if exist !logFileTmp! ( 72 | del /F !logFile! > NUL 2>&1 73 | move /Y !logFileTmp! !logFile! > NUL 2>&1 74 | ) 75 | 76 | type !logFile! | find /I /V "!pat!" > !logFileTmp! 77 | 78 | del /F /S !logFile! > NUL 2>&1 79 | move /Y !logFileTmp! !logFile! > NUL 2>&1 80 | 81 | goto:eof 82 | REM : ------------------------------------------------------------------ 83 | 84 | REM : function to log info for current host 85 | :log2HostFile 86 | REM : arg1 = msg 87 | set "msg=%~1" 88 | 89 | REM : build a relative path in case of software is installed also in games folders 90 | echo msg=!msg! | find %GAMES_FOLDER% > NUL 2>&1 && set "msg=!msg:%GAMES_FOLDER:"=%=%%GAMES_FOLDER:"=%%!" 91 | 92 | if not exist !logFile! ( 93 | set "logFolder="!BFW_LOGS:"=!"" 94 | if not exist !logFolder! mkdir !logFolder! > NUL 2>&1 95 | goto:logMsg2HostFile 96 | ) 97 | REM : check if the message is not already entierely present 98 | for /F %%i in ('type !logFile! ^| find /I "!msg!"') do goto:eof 99 | 100 | :logMsg2HostFile 101 | echo !msg!>> !logFile! 102 | 103 | goto:eof 104 | REM : ------------------------------------------------------------------ 105 | 106 | 107 | REM : function to get and set char set code for current host 108 | :setCharSet 109 | 110 | REM : get charset code for current HOST 111 | set "CHARSET=NOT_FOUND" 112 | for /F "tokens=2 delims=~=" %%f in ('wmic os get codeset /value 2^>NUL ^| find "="') do set "CHARSET=%%f" 113 | 114 | if ["%CHARSET%"] == ["NOT_FOUND"] ( 115 | echo Host char codeSet not found in %0 ^? 116 | pause 117 | exit /b 9 118 | ) 119 | REM : set char code set, output to host log file 120 | 121 | chcp %CHARSET% > NUL 2>&1 122 | call:log2HostFile "charCodeSet=%CHARSET%" 123 | 124 | goto:eof 125 | REM : ------------------------------------------------------------------ 126 | 127 | REM : function to log info for current host 128 | :log2HostFile 129 | REM : arg1 = msg 130 | set "msg=%~1" 131 | 132 | if not exist !logFile! ( 133 | set "logFolder="!BFW_PATH:"=!\logs"" 134 | if not exist !logFolder! mkdir !logFolder! > NUL 2>&1 135 | goto:logMsg2HostFile 136 | ) 137 | REM : check if the message is not already entierely present 138 | for /F %%i in ('type !logFile! ^| find /I "!msg!"') do goto:eof 139 | :logMsg2HostFile 140 | echo !msg!>> !logFile! 141 | 142 | goto:eof 143 | REM : ------------------------------------------------------------------ -------------------------------------------------------------------------------- /tools/downloadGames.bat: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/tools/downloadGames.bat -------------------------------------------------------------------------------- /tools/downloadTitleId.bat: -------------------------------------------------------------------------------- 1 | @echo off 2 | color f0 3 | setlocal EnableExtensions 4 | REM : ------------------------------------------------------------------ 5 | REM : main 6 | 7 | setlocal EnableDelayedExpansion 8 | 9 | color 4F 10 | 11 | set "THIS_SCRIPT=%~0" 12 | 13 | REM : directory of this script 14 | set "SCRIPT_FOLDER="%~dp0"" && set "BFW_TOOLS_PATH=!SCRIPT_FOLDER:\"="!" 15 | 16 | for %%a in (!BFW_TOOLS_PATH!) do set "parentFolder="%%~dpa"" 17 | set "BFW_PATH=!parentFolder:~0,-2!"" 18 | for %%a in (!BFW_PATH!) do set "parentFolder="%%~dpa"" 19 | for %%a in (!BFW_PATH!) do set "drive=%%~da" 20 | set "GAMES_FOLDER=!parentFolder!" 21 | if not [!GAMES_FOLDER!] == ["!drive!\"] set "GAMES_FOLDER=!parentFolder:~0,-2!"" 22 | 23 | set "BFW_RESOURCES_PATH="!BFW_PATH:"=!\resources"" 24 | set "BFW_LOGS="!BFW_PATH:"=!\logs"" 25 | set "logFile="!BFW_LOGS:"=!\Host_!USERDOMAIN!.log"" 26 | 27 | set "Start="!BFW_RESOURCES_PATH:"=!\vbs\Start.vbs"" 28 | 29 | call:setCharSet 30 | 31 | REM : check if java is installed 32 | java -version > NUL 2>&1 33 | if !ERRORLEVEL! NEQ 0 ( 34 | echo ERROR^: java is not installed^, exiting 35 | tiemout /T 10 > NUL 2>&1 36 | exit /b 50 37 | ) 38 | 39 | REM : number of downloading attempts 40 | set dlLoopCount=15 41 | 42 | REM : checking arguments 43 | set /A "nbArgs=0" 44 | :continue 45 | if "%~1"=="" goto:end 46 | set "args[%nbArgs%]="%~1"" 47 | set /A "nbArgs +=1" 48 | shift 49 | goto:continue 50 | :end 51 | 52 | if %nbArgs% LSS 3 ( 53 | echo ERROR ^: on arguments passed ^! 54 | echo SYNTAXE ^: "!THIS_SCRIPT!" JNUSTFolder titleId decryptMode titleKey^* 55 | echo given {%*} 56 | exit /b 99 57 | ) 58 | if %nbArgs% GTR 4 ( 59 | echo ERROR ^: on arguments passed ^! 60 | echo SYNTAXE ^: "!THIS_SCRIPT!" JNUSTFolder titleId decryptMode titleKey^* 61 | echo given {%*} 62 | exit /b 99 63 | ) 64 | 65 | REM : get args 66 | set "JNUSTFolder=!args[0]!" 67 | set "jarFile="!JNUSTFolder:"=!\JNUSTool.jar"" 68 | 69 | if not exist !jarFile! ( 70 | echo ERROR^: JNUSTool^.jar was not found^, exiting 71 | tiemout /T 10 > NUL 2>&1 72 | exit /b 51 73 | ) 74 | pushd !JNUSTFolder! 75 | 76 | set "titleId=!args[1]!" 77 | set "titleId=!titleId:"=!" 78 | 79 | set "arg2=!args[2]!" 80 | set /A "decryptMode=!arg2:"=!" 81 | 82 | set "titleKey=" 83 | if %nbArgs% EQU 4 ( 84 | set "titleKey=!args[3]!" 85 | set "titleKey=!titleKey:"=!" 86 | ) 87 | cls 88 | echo =============================================================== 89 | if !decryptMode! EQU 1 ( 90 | title Downloading RPX version of !titleId! 91 | echo Downloading RPX version of !titleId! 92 | ) else ( 93 | title Downloading WUP version of !titleId! 94 | echo Downloading WUP version of !titleId! 95 | ) 96 | echo =============================================================== 97 | 98 | set "jnArgs=-dlEncrypted" 99 | 100 | if !decryptMode! EQU 1 ( 101 | if ["!titleKey!"] == [""] ( 102 | REM : get titleKeys 103 | for /F "delims=~ tokens=1-4" %%a in ('type titleKeys.txt ^| find /I "!titleId!" 2^>NUL') do ( 104 | set "titleKey=%%b" 105 | ) 106 | if ["!titleKey!"] == [""] ( 107 | echo ERROR^: Sorry^, can^t find a title Key for !titleId! 108 | goto:eof 109 | ) 110 | ) 111 | set "jnArgs=!titleKey! -file /.*" 112 | ) 113 | 114 | for /l %%x in (1, 1, %dlLoopCount%) do ( 115 | Title Downloading !titleId! - pass = %%x/%dlLoopCount% 116 | java -jar JNUSTool.jar !titleId! !jnArgs! 117 | ) 118 | 119 | exit /b 0 120 | 121 | goto:eof 122 | 123 | REM : ------------------------------------------------------------------ 124 | REM : functions 125 | 126 | 127 | REM : function to get and set char set code for current host 128 | :setCharSet 129 | 130 | REM : get charset code for current HOST 131 | set "CHARSET=NOT_FOUND" 132 | for /F "tokens=2 delims=~=" %%f in ('wmic os get codeset /value 2^>NUL ^| find "="') do set "CHARSET=%%f" 133 | 134 | if ["%CHARSET%"] == ["NOT_FOUND"] ( 135 | echo Host char codeSet not found in %0 ^? 136 | exit /b 9 137 | ) 138 | REM : set char code set, output to host log file 139 | 140 | chcp %CHARSET% > NUL 2>&1 141 | 142 | goto:eof 143 | REM : ------------------------------------------------------------------ 144 | 145 | -------------------------------------------------------------------------------- /tools/fixBatFiles.bat: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/tools/fixBatFiles.bat -------------------------------------------------------------------------------- /tools/ftpReplaceFolders.bat: -------------------------------------------------------------------------------- 1 | @echo off 2 | setlocal EnableExtensions 3 | REM : ------------------------------------------------------------------ 4 | REM : main 5 | 6 | setlocal EnableDelayedExpansion 7 | 8 | color 4F 9 | set "THIS_SCRIPT=%~0" 10 | 11 | REM : directory of this script 12 | set "SCRIPT_FOLDER="%~dp0"" && set "BFW_TOOLS_PATH=!SCRIPT_FOLDER:\"="!" 13 | 14 | for %%a in (!BFW_TOOLS_PATH!) do set "parentFolder="%%~dpa"" 15 | set "BFW_PATH=!parentFolder:~0,-2!"" 16 | for %%a in (!BFW_PATH!) do set "parentFolder="%%~dpa"" 17 | for %%a in (!BFW_PATH!) do set "drive=%%~da" 18 | set "GAMES_FOLDER=!parentFolder!" 19 | if not [!GAMES_FOLDER!] == ["!drive!\"] set "GAMES_FOLDER=!parentFolder:~0,-2!"" 20 | 21 | set "BFW_RESOURCES_PATH="!BFW_PATH:"=!\resources"" 22 | 23 | set "WinScpFolder="!BFW_RESOURCES_PATH:"=!\winSCP"" 24 | set "WinScp="!WinScpFolder:"=!\WinScp.com"" 25 | 26 | 27 | set "myLog="!BFW_PATH:"=!\logs\ftpSyncFolders.log"" 28 | 29 | REM : set current char codeset 30 | call:setCharSet 31 | 32 | REM : checking arguments 33 | set /A "nbArgs=0" 34 | :continue 35 | if "%~1"=="" goto:end 36 | set "args[%nbArgs%]="%~1"" 37 | set /A "nbArgs +=1" 38 | shift 39 | goto:continue 40 | :end 41 | 42 | if %nbArgs% GTR 5 ( 43 | echo ERROR on arguments passed ^(%nbArgs%^) 44 | echo SYNTAX^: "!THIS_SCRIPT!" WII-U_IP SYNC_TYPE LOCAL_FOLDER REMOTE_FOLDER TITLE 45 | echo given {%*} 46 | pause 47 | exit /b 9 48 | ) 49 | if %nbArgs% LSS 4 ( 50 | echo ERROR on arguments passed ^(%nbArgs%^) 51 | echo SYNTAX^: "!THIS_SCRIPT!" WII-U_IP SYNC_TYPE LOCAL_FOLDER REMOTE_FOLDER TITLE 52 | echo given {%*} 53 | pause 54 | exit /b 9 55 | ) 56 | 57 | REM : get and check wiiuIp 58 | set "wiiuIp=!args[0]!" 59 | ping -n 1 !wiiuIp! > NUL 2>&1 60 | if !ERRORLEVEL! NEQ 0 ( 61 | echo ERROR^: !wiiuIp! was not found on your network ^! 62 | pause 63 | exit /b 1 64 | ) 65 | set "wiiuIp=!wiiuIp:"=!" 66 | 67 | set "SYNC_TYPE=!args[1]!" 68 | if not [!SYNC_TYPE!] == ["local"] if not [!SYNC_TYPE!] == ["remote"] ( 69 | echo ERROR ^: !SYNC_TYPE! not equal to ^'local^' neither ^'remote^'" 70 | pause 71 | exit /b 2 72 | ) 73 | set "SYNC_TYPE=!SYNC_TYPE:"=!" 74 | set "LOCAL_FOLDER=!args[2]!" 75 | set "REMOTE_FOLDER=!args[3]!" 76 | 77 | echo ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 78 | if %nbArgs% EQU 5 ( 79 | set "SITENAME=!args[4]!" 80 | set "SITENAME=!SITENAME:"=!" 81 | 82 | echo FTP transfert !USERDOMAIN! ^<-^> !wiiuIp! 83 | echo !SITENAME! 84 | set "myLog="!BFW_PATH:"=!\logs\ftpSyncFolders_!SITENAME!.log"" 85 | ) else ( 86 | echo FTP transfert !USERDOMAIN! ^<-^> !wiiuIp! ^: 87 | ) 88 | echo ---------------------------------------------------------- 89 | 90 | REM : create localFolder if needed 91 | if not exist !LOCAL_FOLDER! mkdir !LOCAL_FOLDER! > NUL 2>&1 92 | 93 | if ["!SYNC_TYPE!"] == ["local"] ( 94 | if exist !LOCAL_FOLDER! ( 95 | rmdir /Q /S !LOCAL_FOLDER! > NUL 2>&1 96 | ) 97 | mkdir !LOCAL_FOLDER! > NUL 2>&1 98 | echo ^> Replacing !LOCAL_FOLDER! content with !REMOTE_FOLDER! one 99 | ) else ( 100 | REM : if remote mode, delete remote folder 101 | set "ftpmyLog="!BFW_PATH:"=!\logs\ftpCheck.log"" 102 | !winScp! /command "option batch on" "open ftp://USER:PASSWD@!wiiuIp!/ -timeout=5 -rawsettings FollowDirectorySymlinks=1 FtpForcePasvIp2=0 FtpPingType=0" "rm "!REMOTE_FOLDER!"" "exit" > !ftpmyLog! 2>&1 103 | !winScp! /command "option batch on" "open ftp://USER:PASSWD@!wiiuIp!/ -timeout=5 -rawsettings FollowDirectorySymlinks=1 FtpForcePasvIp2=0 FtpPingType=0" "mkdir "!REMOTE_FOLDER!"" "exit" > !ftpmyLog! 2>&1 104 | echo ^> Replacing !REMOTE_FOLDER! content with !LOCAL_FOLDER! one 105 | ) 106 | 107 | REM : run ftp transferts ^: 108 | !winScp! /command "open ftp://USER:PASSWD@!wiiuIp!/ -timeout=5 -rawsettings FollowDirectorySymlinks=1 FtpForcePasvIp2=0 FtpPingType=0" "option batch continue" "synchronize !SYNC_TYPE! "!LOCAL_FOLDER!" "!REMOTE_FOLDER!"" "option batch off" "exit" 109 | set "cr=!ERRORLEVEL!" 110 | if !cr! NEQ 0 echo ERROR detected when transferring ^! 111 | echo ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 112 | 113 | if !cr! NEQ 0 exit /b !cr! 114 | exit /b 0 115 | 116 | goto:eof 117 | REM : ------------------------------------------------------------------ 118 | 119 | 120 | 121 | REM : ------------------------------------------------------------------ 122 | REM : functions 123 | 124 | 125 | REM : function to get and set char set code for current host 126 | :setCharSet 127 | 128 | REM : get charset code for current HOST 129 | set "CHARSET=NOT_FOUND" 130 | for /F "tokens=2 delims=~=" %%f in ('wmic os get codeset /value 2^>NUL ^| find "="') do set "CHARSET=%%f" 131 | 132 | if ["%CHARSET%"] == ["NOT_FOUND"] ( 133 | echo Host char codeSet not found ^?^, exiting 1 134 | timeout /t 8 > NUL 2>&1 135 | exit /b 9 136 | ) 137 | REM : set char code set, output to host log file 138 | 139 | chcp %CHARSET% > NUL 2>&1 140 | 141 | REM : get locale for current HOST 142 | set "L0CALE_CODE=NOT_FOUND" 143 | for /F "tokens=2 delims=~=" %%f in ('wmic path Win32_OperatingSystem get Locale /value 2^>NUL ^| find "="') do set "L0CALE_CODE=%%f" 144 | 145 | goto:eof 146 | REM : ------------------------------------------------------------------ 147 | -------------------------------------------------------------------------------- /tools/ftpSetWiiuFirmwareUpdateMode.bat: -------------------------------------------------------------------------------- 1 | @echo off 2 | setlocal EnableExtensions 3 | REM : ------------------------------------------------------------------ 4 | REM : main 5 | 6 | setlocal EnableDelayedExpansion 7 | 8 | color 4F 9 | set "THIS_SCRIPT=%~0" 10 | 11 | title Set Wii-U Firmware Update Mode 12 | 13 | REM : directory of this script 14 | set "SCRIPT_FOLDER="%~dp0"" && set "BFW_TOOLS_PATH=!SCRIPT_FOLDER:\"="!" 15 | 16 | for %%a in (!BFW_TOOLS_PATH!) do set "parentFolder="%%~dpa"" 17 | set "BFW_PATH=!parentFolder:~0,-2!"" 18 | for %%a in (!BFW_PATH!) do set "parentFolder="%%~dpa"" 19 | for %%a in (!BFW_PATH!) do set "drive=%%~da" 20 | set "GAMES_FOLDER=!parentFolder!" 21 | if not [!GAMES_FOLDER!] == ["!drive!\"] set "GAMES_FOLDER=!parentFolder:~0,-2!"" 22 | 23 | set "BFW_RESOURCES_PATH="!BFW_PATH:"=!\resources"" 24 | set "logFile="!BFW_PATH:"=!\logs\Host_!USERDOMAIN!.log"" 25 | 26 | REM : set current char codeset 27 | call:setCharSet 28 | 29 | REM : checking arguments 30 | set /A "nbArgs=0" 31 | :continue 32 | if "%~1"=="" goto:end 33 | set "args[%nbArgs%]="%~1"" 34 | set /A "nbArgs +=1" 35 | shift 36 | goto:continue 37 | :end 38 | 39 | if %nbArgs% NEQ 0 goto:treatArgs 40 | 41 | echo ========================================================= 42 | echo Set the WiiU firmware update feature mode 43 | echo ========================================================= 44 | echo. 45 | echo y : enabling firmware update on the Wii-U 46 | echo n : disabling firmware update on the Wii-U 47 | 48 | REM : Wii-U firmaware update mode 49 | REM : 0 : disable update 50 | REM : 1 : enable update 51 | set /A "wfum=0" 52 | 53 | 54 | echo. 55 | choice /C yn /N /M "Do you want to enable the firmware update on you Wii-U (y, n)? : " 56 | if !ERRORLEVEL! EQU 1 set /A "wfum=1 57 | 58 | if !wfum! EQU 1 ( 59 | echo Continue with allowing firmware upate on your Wii-U ^? 60 | echo. 61 | pause 62 | ) else ( 63 | echo Continue with disabling firmware upate on your Wii-U ^? 64 | echo. 65 | pause 66 | ) 67 | goto:inputsAvailable 68 | 69 | :treatArgs 70 | if %nbArgs% GTR 1 ( 71 | echo ERROR on arguments passed ^(%nbArgs%^) 72 | echo SYNTAX^: "!THIS_SCRIPT!" OFF^(or ON^) 73 | echo given {%*} 74 | pause 75 | exit /b 9 76 | ) 77 | 78 | REM : get and check GAME_FOLDER_PATH 79 | set "str=!args[0]!" 80 | if [!str!] == ["ON"] set /A "wfum=1" 81 | 82 | 83 | :inputsAvailable 84 | cls 85 | 86 | if !wfum! EQU 1 ( 87 | title Enabling Wii-U Firmware Update feature 88 | ) else ( 89 | title Disabling Wii-U Firmware Update feature 90 | ) 91 | 92 | echo On your Wii-U^, you need to ^: 93 | echo - launch WiiU FTP Server and press B to mount NAND paths 94 | echo - get the IP adress displayed on Wii-U gamepad 95 | echo. 96 | echo Press any key to continue when you^'re ready 97 | echo ^(CTRL-C^) to abort 98 | pause 99 | cls 100 | 101 | set "WinScpFolder="!BFW_RESOURCES_PATH:"=!\winSCP"" 102 | set "WinScp="!WinScpFolder:"=!\WinScp.com"" 103 | set "winScpIniTmpl="!WinScpFolder:"=!\WinSCP.ini-tmpl"" 104 | set "winScpIni="!WinScpFolder:"=!\WinScp.ini"" 105 | 106 | if not exist !winScpIni! goto:getWiiuIp 107 | 108 | REM : get the hostname 109 | set "ipRead=" 110 | for /F "delims=~= tokens=2" %%i in ('type !winScpIni! ^| find "HostName="') do set "ipRead=%%i" 111 | if ["!ipRead!"] == [""] goto:getWiiuIp 112 | REM : and the port 113 | set "portRead=" 114 | for /F "delims=~= tokens=2" %%i in ('type !winScpIni! ^| find "PortNumber="') do set "portRead=%%i" 115 | if ["!portRead!"] == [""] goto:getWiiuIp 116 | 117 | echo Found an existing FTP configuration ^: 118 | echo. 119 | echo PortNumber=!ipRead! 120 | echo HostName=!portRead! 121 | echo. 122 | choice /C yn /N /M "Use this setup (y, n)? : " 123 | if !ERRORLEVEL! EQU 1 set "wiiuIp=!ipRead!" && goto:checkConnection 124 | 125 | :getWiiuIp 126 | set /P "wiiuIp=Please enter your Wii-U local IP adress : " 127 | set /P "port=Please enter the port used : " 128 | 129 | set "winScpIniTmpl="!WinScpFolder:"=!\WinSCP.ini-tmpl"" 130 | 131 | 132 | REM : prepare winScp.ini file 133 | copy /Y !winScpIniTmpl! !winScpIni! > NUL 2>&1 134 | set "fnrLog="!BFW_PATH:"=!\logs\fnr_WinScp.log"" 135 | 136 | REM : set WiiU ip adress 137 | !StartHiddenWait! !fnrPath! --cl --dir !WinScpFolder! --fileMask WinScp.ini --find "FTPiiU-IP" --replace "!wiiuIp!" --logFile !fnrLog! 138 | !StartHiddenWait! !fnrPath! --cl --dir !WinScpFolder! --fileMask WinScp.ini --find "FTPiiU-port" --replace "!port!" --logFile !fnrLog! 139 | 140 | :checkConnection 141 | cls 142 | REM : check its state 143 | set /A "state=0" 144 | call:getHostState !wiiuIp! state 145 | 146 | if !state! EQU 0 ( 147 | echo ERROR^: !wiiuIp! was not found on your network ^! 148 | echo exiting 2 149 | if %nbArgs% EQU 0 pause && exit 2 150 | if %nbArgs% NEQ 0 exit /b 2 151 | ) 152 | 153 | set "ftplogFile="!BFW_PATH:"=!\logs\ftpCheck_swfum.log"" 154 | !winScp! /command "option batch on" "open ftp://USER:PASSWD@!wiiuIp!/ -timeout=5 -rawsettings FollowDirectorySymlinks=1 FtpForcePasvIp2=0 FtpPingType=0" "ls /storage_mlc/usr/save/system/act" "exit" > !ftplogFile! 2>&1 155 | type !ftplogFile! | find /I "Connection failed" > NUL 2>&1 && ( 156 | echo ERROR ^: unable to connect^, check that your Wii-U is powered on and that 157 | echo WiiuFtpServer was launched with mounting NAND paths ^(press B^) 158 | echo Pause this script until you fix it ^(CTRL-C to abort^) 159 | pause 160 | goto:checkConnection 161 | ) 162 | type !ftplogFile! | find /I "Could not retrieve directory listing" > NUL 2>&1 && ( 163 | echo ERROR ^: unable to list games on NAND^, launch MOCHA CFW before WiiuFtpServer on the Wii-U 164 | echo Pause this script until you fix it ^(CTRL-C to abort^) 165 | pause 166 | goto:checkConnection 167 | ) 168 | cls 169 | 170 | REM : in function of wfum 171 | if !wfum! EQU 0 ( 172 | echo. 173 | echo Disabling firmware update on your Wii-U^.^.^. 174 | echo. 175 | REM : disable firmware update on the Wii-U 176 | !winScp! /command "open ftp://USER:PASSWD@!wiiuIp!/ -timeout=5 -rawsettings FollowDirectorySymlinks=1 FtpForcePasvIp2=0 FtpPingType=0" "option batch on" "rmdir /storage_mlc/sys/update" "option batch off" "exit" > !ftplogFile! 2>&1 177 | 178 | ) else ( 179 | REM : enable firmware update on the Wii-U 180 | echo. 181 | echo Enabling firmware update on your Wii-U^.^.^. 182 | echo. 183 | !winScp! /command "open ftp://USER:PASSWD@!wiiuIp!/ -timeout=5 -rawsettings FollowDirectorySymlinks=1 FtpForcePasvIp2=0 FtpPingType=0" "option batch on" "mkdir /storage_mlc/sys/update" "option batch off" "exit" > !ftplogFile! 2>&1 184 | ) 185 | echo done 186 | 187 | if %nbArgs% EQU 0 pause & exit 0 188 | if %nbArgs% NEQ 0 timeout /T 4 > NUL 2>&1 & exit /b 0 189 | 190 | goto:eof 191 | REM : ------------------------------------------------------------------ 192 | 193 | 194 | 195 | REM : ------------------------------------------------------------------ 196 | REM : functions 197 | 198 | :getHostState 199 | set "ipaddr=%~1" 200 | set /A "state=0" 201 | ping -n 1 !ipaddr! > NUL 2>&1 202 | if !ERRORLEVEL! EQU 0 set /A "state=1" 203 | 204 | set "%2=%state%" 205 | goto:eof 206 | REM : ------------------------------------------------------------------ 207 | 208 | 209 | REM : function to get and set char set code for current host 210 | :setCharSet 211 | 212 | REM : get charset code for current HOST 213 | set "CHARSET=NOT_FOUND" 214 | for /F "tokens=2 delims=~=" %%f in ('wmic os get codeset /value 2^>NUL ^| find "="') do set "CHARSET=%%f" 215 | 216 | if ["%CHARSET%"] == ["NOT_FOUND"] ( 217 | echo Host char codeSet not found in %0 ^? 218 | timeout /t 8 > NUL 2>&1 219 | exit /b 9 220 | ) 221 | REM : set char code set, output to host log file 222 | 223 | chcp %CHARSET% > NUL 2>&1 224 | 225 | REM : get locale for current HOST 226 | set "L0CALE_CODE=NOT_FOUND" 227 | for /F "tokens=2 delims=~=" %%f in ('wmic path Win32_OperatingSystem get Locale /value 2^>NUL ^| find "="') do set "L0CALE_CODE=%%f" 228 | 229 | goto:eof 230 | REM : ------------------------------------------------------------------ 231 | 232 | -------------------------------------------------------------------------------- /tools/ftpSyncFolders.bat: -------------------------------------------------------------------------------- 1 | @echo off 2 | setlocal EnableExtensions 3 | REM : ------------------------------------------------------------------ 4 | REM : main 5 | 6 | setlocal EnableDelayedExpansion 7 | 8 | color 4F 9 | set "THIS_SCRIPT=%~0" 10 | 11 | REM : directory of this script 12 | set "SCRIPT_FOLDER="%~dp0"" && set "BFW_TOOLS_PATH=!SCRIPT_FOLDER:\"="!" 13 | 14 | for %%a in (!BFW_TOOLS_PATH!) do set "parentFolder="%%~dpa"" 15 | set "BFW_PATH=!parentFolder:~0,-2!"" 16 | for %%a in (!BFW_PATH!) do set "parentFolder="%%~dpa"" 17 | for %%a in (!BFW_PATH!) do set "drive=%%~da" 18 | set "GAMES_FOLDER=!parentFolder!" 19 | if not [!GAMES_FOLDER!] == ["!drive!\"] set "GAMES_FOLDER=!parentFolder:~0,-2!"" 20 | 21 | set "BFW_RESOURCES_PATH="!BFW_PATH:"=!\resources"" 22 | 23 | set "WinScpFolder="!BFW_RESOURCES_PATH:"=!\winSCP"" 24 | set "WinScp="!WinScpFolder:"=!\WinScp.com"" 25 | 26 | for /F "usebackq tokens=1,2 delims=~=" %%i in (`wmic os get LocalDateTime /VALUE 2^>NUL`) do if '.%%i.'=='.LocalDateTime.' set "ldt=%%j" 27 | set "ldt=%ldt:~0,4%-%ldt:~4,2%-%ldt:~6,2%_%ldt:~8,2%-%ldt:~10,2%-%ldt:~12,6%" 28 | set "DATE=%ldt%" 29 | 30 | set "myLog="!BFW_PATH:"=!\logs\ftpSyncFolders.log"" 31 | 32 | REM : set current char codeset 33 | call:setCharSet 34 | 35 | REM : checking arguments 36 | set /A "nbArgs=0" 37 | :continue 38 | if "%~1"=="" goto:end 39 | set "args[%nbArgs%]="%~1"" 40 | set /A "nbArgs +=1" 41 | shift 42 | goto:continue 43 | :end 44 | 45 | if %nbArgs% GTR 5 ( 46 | echo ERROR on arguments passed ^(%nbArgs%^) 47 | echo SYNTAX^: "!THIS_SCRIPT!" WII-U_IP SYNC_TYPE LOCAL_FOLDER REMOTE_FOLDER SITENAME 48 | echo given {%*} 49 | pause 50 | exit /b 9 51 | ) 52 | if %nbArgs% LSS 4 ( 53 | echo ERROR on arguments passed ^(%nbArgs%^) 54 | echo SYNTAX^: "!THIS_SCRIPT!" WII-U_IP SYNC_TYPE LOCAL_FOLDER REMOTE_FOLDER SITENAME 55 | echo given {%*} 56 | pause 57 | exit /b 9 58 | ) 59 | 60 | REM : get and check wiiuIp 61 | set "wiiuIp=!args[0]!" 62 | ping -n 1 !wiiuIp! > NUL 2>&1 63 | if !ERRORLEVEL! NEQ 0 ( 64 | echo ERROR^: !wiiuIp! was not found on your network ^! 65 | pause 66 | exit /b 1 67 | ) 68 | set "wiiuIp=!wiiuIp:"=!" 69 | 70 | set "SYNC_TYPE=!args[1]!" 71 | if not [!SYNC_TYPE!] == ["local"] if not [!SYNC_TYPE!] == ["remote"] ( 72 | echo ERROR ^: !SYNC_TYPE! not equal to ^'local^' neither ^'remote^'" 73 | pause 74 | exit /b 2 75 | ) 76 | set "SYNC_TYPE=!SYNC_TYPE:"=!" 77 | set "LOCAL_FOLDER=!args[2]!" 78 | set "REMOTE_FOLDER=!args[3]!" 79 | 80 | echo ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 81 | if %nbArgs% EQU 5 ( 82 | set "SITENAME=!args[4]!" 83 | set "SITENAME=!SITENAME:"=!" 84 | 85 | echo FTP transfert !USERDOMAIN! ^<-^> !wiiuIp! 86 | echo !SITENAME! 87 | set "myLog="!BFW_PATH:"=!\logs\ftpSyncFolders_!SITENAME!.log"" 88 | ) else ( 89 | echo FTP transfert !USERDOMAIN! ^<-^> !wiiuIp! ^: 90 | ) 91 | echo ---------------------------------------------------------- 92 | 93 | REM : create localFolder if needed 94 | set /A "nbRetry=0" 95 | 96 | if ["!SYNC_TYPE!"] == ["local"] ( 97 | if not exist !LOCAL_FOLDER! mkdir !LOCAL_FOLDER! > NUL 2>&1 98 | ) else ( 99 | set "ftplogFile="!BFW_PATH:"=!\logs\ftpCheckBeforeSync_!DATE!.log"" 100 | 101 | !winScp! /command "option batch on" "open ftp://USER:PASSWD@!wiiuIp!/ -timeout=5 -rawsettings FollowDirectorySymlinks=1 FtpForcePasvIp2=0 FtpPingType=0" "mkdir "!REMOTE_FOLDER!"" "option batch off" "exit" > !ftplogFile! 102 | !winScp! /command "option batch on" "open ftp://USER:PASSWD@!wiiuIp!/ -timeout=5 -rawsettings FollowDirectorySymlinks=1 FtpForcePasvIp2=0 FtpPingType=0" "ls "!REMOTE_FOLDER!"" "option batch off" "exit" > !ftplogFile! 103 | type !ftplogFile! | find /I "Could not retrieve directory listing" > NUL 2>&1 && ( 104 | echo ERROR ^: unable to create !REMOTE_FOLDER! 105 | pause 106 | exit /b 50 107 | ) 108 | ) 109 | del /F !ftplogFile! > NUL 2>&1 110 | echo. 111 | echo ^> Sync !SYNC_TYPE! !LOCAL_FOLDER! !REMOTE_FOLDER! 112 | 113 | REM : run ftp transferts : 114 | !winScp! /log=!myLog! /command "open ftp://USER:PASSWD@!wiiuIp!/ -timeout=5 -rawsettings FollowDirectorySymlinks=1 FtpForcePasvIp2=0 FtpPingType=0" "option batch continue" "synchronize !SYNC_TYPE! "!LOCAL_FOLDER!" "!REMOTE_FOLDER!"" "option batch off" "exit" 115 | set "cr=!ERRORLEVEL!" 116 | if !cr! NEQ 0 echo ERROR detected when transferring ^! 117 | echo ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 118 | 119 | if !cr! NEQ 0 exit /b !cr! 120 | exit /b 0 121 | 122 | goto:eof 123 | REM : ------------------------------------------------------------------ 124 | 125 | 126 | 127 | REM : ------------------------------------------------------------------ 128 | REM : functions 129 | 130 | 131 | REM : function to get and set char set code for current host 132 | :setCharSet 133 | 134 | REM : get charset code for current HOST 135 | set "CHARSET=NOT_FOUND" 136 | for /F "tokens=2 delims=~=" %%f in ('wmic os get codeset /value 2^>NUL ^| find "="') do set "CHARSET=%%f" 137 | 138 | if ["%CHARSET%"] == ["NOT_FOUND"] ( 139 | echo Host char codeSet not found in %0 ^? 140 | timeout /t 8 > NUL 2>&1 141 | exit /b 9 142 | ) 143 | REM : set char code set, output to host log file 144 | 145 | chcp %CHARSET% > NUL 2>&1 146 | 147 | REM : get locale for current HOST 148 | set "L0CALE_CODE=NOT_FOUND" 149 | for /F "tokens=2 delims=~=" %%f in ('wmic path Win32_OperatingSystem get Locale /value 2^>NUL ^| find "="') do set "L0CALE_CODE=%%f" 150 | 151 | goto:eof 152 | REM : ------------------------------------------------------------------ 153 | -------------------------------------------------------------------------------- /tools/getDllOrExeVersion.bat: -------------------------------------------------------------------------------- 1 | @if (@this==@isBatch) @then 2 | @echo off 3 | setlocal enableextensions 4 | 5 | set "file=%~f1" 6 | if not exist "%file%" goto :eof 7 | 8 | cscript //nologo //e:jscript "%~f0" /file:"%file%" 9 | 10 | endlocal 11 | 12 | exit /b 13 | @end 14 | var file = WScript.Arguments.Named.Item('file').replace(/\\/g,'\\\\'); 15 | var wmi = GetObject('winmgmts:{impersonationLevel=impersonate}!\\\\.\\root\\cimv2') 16 | var files = new Enumerator(wmi.ExecQuery('Select Version from CIM_datafile where name=\''+file+'\'')) 17 | 18 | while (!files.atEnd()){ 19 | WScript.StdOut.WriteLine(files.item().Version); 20 | files.moveNext(); 21 | }; 22 | WScript.Quit(0) 23 | -------------------------------------------------------------------------------- /tools/initProgressBar.bat: -------------------------------------------------------------------------------- 1 | @echo off 2 | color f 3 | setlocal EnableExtensions 4 | REM : ------------------------------------------------------------------ 5 | REM : main 6 | 7 | setlocal EnableDelayedExpansion 8 | 9 | set "THIS_SCRIPT=%~0" 10 | 11 | REM : directory of this script 12 | set "SCRIPT_FOLDER="%~dp0"" && set "BFW_TOOLS_PATH=!SCRIPT_FOLDER:\"="!" 13 | for %%a in (!BFW_TOOLS_PATH!) do set "parentFolder="%%~dpa"" 14 | set "BFW_PATH=!parentFolder:~0,-2!"" 15 | 16 | set "BFW_RESOURCES_PATH="!BFW_PATH:"=!\resources"" 17 | set "BFW_TOOLS_PATH="!BFW_PATH:"=!\tools"" 18 | set "cmdOw="!BFW_RESOURCES_PATH:"=!\cmdOw.exe"" 19 | set "logFile="!BFW_PATH:"=!\logs\Host_!USERDOMAIN!.log"" 20 | 21 | REM : create the shortcut in !BFW_RESOURCES_PATH! 22 | call:fixShortcut 23 | 24 | pushd !BFW_RESOURCES_PATH! 25 | 26 | for /f "tokens=2,10-11" %%a in ('cmdOw.exe /p') do ( 27 | if "%%a"=="0" set "scrWidth=%%b" & set "scrHeight=%%c" 28 | ) 29 | 30 | REM : flush logFile of RESOLUTION 31 | call:cleanHostLogFile RESOLUTION 32 | 33 | set "msg="RESOLUTION=!scrWidth!x!scrHeight!"" 34 | call:log2HostFile !msg! 35 | 36 | exit 0 37 | goto:eof 38 | 39 | 40 | REM : ------------------------------------------------------------------ 41 | 42 | REM : ------------------------------------------------------------------ 43 | REM : functions 44 | 45 | :cleanHostLogFile 46 | REM : pattern to ignore in log file 47 | set "pat=%~1" 48 | set "logFileTmp="!logFile:"=!.bfw_tmp"" 49 | if exist !logFileTmp! ( 50 | del /F !logFile! > NUL 2>&1 51 | move /Y !logFileTmp! !logFile! > NUL 2>&1 52 | ) 53 | 54 | type !logFile! | find /I /V "!pat!" > !logFileTmp! 55 | 56 | del /F /S !logFile! > NUL 2>&1 57 | move /Y !logFileTmp! !logFile! > NUL 2>&1 58 | 59 | goto:eof 60 | REM : ------------------------------------------------------------------ 61 | 62 | REM : function to update the shortcuts folder that become obsolete 63 | :fixShortcut 64 | 65 | set "shortcut="!BFW_RESOURCES_PATH:"=!\progressBar.lnk"" 66 | set "target="!BFW_TOOLS_PATH:"=!\progressBar.bat"" 67 | set "icon="!BFW_RESOURCES_PATH:"=!\icons\BatchFw.ico"" 68 | 69 | REM : create a tempory vbs script 70 | set "TMP_VBS_FILE="!TEMP!\BatchFw_progressBar.vbs"" 71 | 72 | REM : create script file 73 | echo set oWS = WScript^.CreateObject^("WScript.Shell"^) > !TMP_VBS_FILE! 74 | echo set oSc = oWS^.CreateShortcut^(!shortcut!^) >> !TMP_VBS_FILE! 75 | echo oSc^.TargetPath = !target! >> !TMP_VBS_FILE! 76 | echo oSc^.WorkingDirectory = !BFW_TOOLS_PATH! >> !TMP_VBS_FILE! 77 | echo oSc^.IconLocation = !icon! >> !TMP_VBS_FILE! 78 | 79 | echo oSc^.Save >> !TMP_VBS_FILE! 80 | 81 | REM : running VBS file 82 | cscript /nologo !TMP_VBS_FILE! 83 | 84 | if !ERRORLEVEL! EQU 0 del /F !TMP_VBS_FILE! > NUL 2>&1 85 | goto:eof 86 | REM : ------------------------------------------------------------------ 87 | 88 | 89 | REM : function to log info for current host 90 | :log2HostFile 91 | REM : arg1 = msg 92 | set "msg=%~1" 93 | 94 | REM : build a relative path in case of software is installed also in games folders 95 | echo msg=!msg! | find %GAMES_FOLDER% > NUL 2>&1 && set "msg=!msg:%GAMES_FOLDER:"=%=%%GAMES_FOLDER:"=%%!" 96 | 97 | if not exist !logFile! ( 98 | set "logFolder="!BFW_LOGS:"=!"" 99 | if not exist !logFolder! mkdir !logFolder! > NUL 2>&1 100 | goto:logMsg2HostFile 101 | ) 102 | REM : check if the message is not already entierely present 103 | for /F %%i in ('type !logFile! ^| find /I "!msg!"') do goto:eof 104 | 105 | :logMsg2HostFile 106 | echo !msg!>> !logFile! 107 | 108 | goto:eof 109 | REM : ------------------------------------------------------------------ 110 | -------------------------------------------------------------------------------- /tools/killBatchFw.bat: -------------------------------------------------------------------------------- 1 | @echo off 2 | setlocal EnableExtensions 3 | title Kill all BatchFw^'s process 4 | REM : ------------------------------------------------------------------ 5 | REM : main 6 | 7 | setlocal EnableDelayedExpansion 8 | color 4F 9 | 10 | REM : directory of this script 11 | set "SCRIPT_FOLDER="%~dp0"" && set "BFW_TOOLS_PATH=!SCRIPT_FOLDER:\"="!" 12 | 13 | for %%a in (!BFW_TOOLS_PATH!) do set "parentFolder="%%~dpa"" 14 | set "BFW_PATH=!parentFolder:~0,-2!"" 15 | for %%a in (!BFW_PATH!) do set "parentFolder="%%~dpa"" 16 | for %%a in (!BFW_PATH!) do set "drive=%%~da" 17 | set "GAMES_FOLDER=!parentFolder!" 18 | if not [!GAMES_FOLDER!] == ["!drive!\"] set "GAMES_FOLDER=!parentFolder:~0,-2!"" 19 | 20 | set "BFW_RESOURCES_PATH="!BFW_PATH:"=!\resources"" 21 | set "StartHiddenWait="!BFW_RESOURCES_PATH:"=!\vbs\StartHiddenWait.vbs"" 22 | set "logFile="!BFW_PATH:"=!\logs\Host_!USERDOMAIN!.log"" 23 | 24 | REM : with no arguments to this script, activating user inputs 25 | set "ignore=" 26 | 27 | REM : checking arguments 28 | set /A "nbArgs=0" 29 | :continue 30 | if "%~1"=="" goto:end 31 | set "args[%nbArgs%]="%~1"" 32 | set /A "nbArgs +=1" 33 | shift 34 | goto:continue 35 | :end 36 | 37 | if %nbArgs% NEQ 0 ( 38 | set "avoid=| find /V " 39 | set /A "na=nbArgs-1" 40 | for /L %%i in (0,1,!na!) do ( 41 | set "item=!args[%%i]!" 42 | set "item=!item:"=!" 43 | set "ignore=!ignore! !avoid!!item!" 44 | ) 45 | ) 46 | 47 | REM : basename of GAME FOLDER PATH 48 | for /F "delims=~" %%i in (!GAMES_FOLDER!) do set "GAMES_FOLDER_NAME=%%~nxi" 49 | 50 | echo --------------------------------------------------------- 51 | echo killing BatchFw^'s process^.^.^. 52 | 53 | for /F "delims=~" %%p in ('wmic path Win32_Process where ^"CommandLine like ^'%%!GAMES_FOLDER_NAME!%%^'^" get ProcessID^,commandline') do ( 54 | set "line=%%p" 55 | set "line2=!line:""="!" 56 | set "pid=NOT_FOUND" 57 | echo !line2! | find /V "wmic" | find /V "ProcessID" | find /V "killBatchFw" !ignore! > NUL 2>&1 && for %%d in (!line2!) do set "pid=%%d" 58 | if not ["!pid!"] == ["NOT_FOUND"] taskkill /F /pid !pid! /T > NUL 2>&1 59 | ) 60 | 61 | echo --------------------------------------------------------- 62 | echo killing CEMU^.^.^. 63 | 64 | REM : kill CEMU's running process 65 | wmic process where "Name like '%%cemu.exe%%'" call terminate > NUL 2>&1 66 | 67 | taskkill /F /IM "Cemu.exe" /T > NUL 2>&1 68 | 69 | REM : stoping user's software 70 | type !logFile! | find /I "TO_BE_LAUNCHED" > NUL 2>&1 && ( 71 | 72 | echo --------------------------------------------------------- 73 | echo killing 3rd party Software^.^.^. 74 | echo --------------------------------------------------------- 75 | 76 | set "stopThirdPartySoftware="!BFW_TOOLS_PATH:"=!\stopThirdPartySoftware.bat"" 77 | wscript /nologo !StartHiddenWait! !stopThirdPartySoftware! 78 | ) 79 | 80 | REM : a second time to kill processes that might have been missed 81 | for /F "delims=~" %%p in ('wmic path Win32_Process where ^"CommandLine like ^'%%!GAMES_FOLDER_NAME!%%^'^" get ProcessID^,commandline 2^>NUL') do ( 82 | set "line=%%p" 83 | set "line2=!line:""="!" 84 | set "pid=NOT_FOUND" 85 | echo !line2! | find /V "wmic" | find /V "ProcessID" | find /V "killBatchFw" !ignore! > NUL 2>&1 && for %%d in (!line2!) do set "pid=%%d" 86 | if not ["!pid!"] == ["NOT_FOUND"] taskkill /F /pid !pid! /T > NUL 2>&1 87 | ) 88 | timeout /T 3 > NUL 2>&1 89 | exit 0 -------------------------------------------------------------------------------- /tools/launchThirdPartySoftware.bat: -------------------------------------------------------------------------------- 1 | @echo off 2 | setlocal EnableExtensions 3 | title BatchFw third party software launcher 4 | REM : ------------------------------------------------------------------ 5 | REM : main 6 | 7 | setlocal EnableDelayedExpansion 8 | color 4F 9 | 10 | set "THIS_SCRIPT=%~0" 11 | 12 | REM : directory of this script 13 | set "SCRIPT_FOLDER="%~dp0"" && set "BFW_TOOLS_PATH=!SCRIPT_FOLDER:\"="!" 14 | 15 | for %%a in (!BFW_TOOLS_PATH!) do set "parentFolder="%%~dpa"" 16 | set "BFW_PATH=!parentFolder:~0,-2!"" 17 | for %%a in (!BFW_PATH!) do set "drive=%%~da" 18 | 19 | set "BFW_RESOURCES_PATH="!BFW_PATH:"=!\resources"" 20 | set "Start="!BFW_RESOURCES_PATH:"=!\vbs\Start.vbs"" 21 | 22 | set "MessageBox="!BFW_RESOURCES_PATH:"=!\vbs\MessageBox.vbs"" 23 | 24 | set "logFile="!BFW_PATH:"=!\logs\Host_!USERDOMAIN!.log"" 25 | 26 | set /A "nbIs=0" 27 | for /F "tokens=2 delims=~@" %%i in ('type !logFile! ^| find /I "TO_BE_LAUNCHED" 2^>NUL') do ( 28 | 29 | set "command=%%i" 30 | for /F "tokens=* delims=~" %%j in ("!command!") do call:resolveVenv "%%j" command 31 | echo command=!command! 32 | 33 | set "program="NONE"" 34 | set "firstArg="NONE"" 35 | 36 | REM : resolve venv for search 37 | for /F "tokens=1 delims=~'" %%j in ("!command!") do set "program="%%j"" 38 | for /F "tokens=3 delims=~'" %%j in ("!command!") do set "firstArg="%%j"" 39 | 40 | echo program=!program! 41 | echo firstArg=!firstArg! 42 | 43 | if not [!program!] == ["NONE"] if not exist !program! ( 44 | 45 | !MessageBox! "WARNING !program! does not exist anymore^, deleting this entry^!" 4144 46 | call:cleanHostLogFile !program:"='! 47 | set /A "nbIs=99" 48 | ) 49 | if !nbIs! NEQ 99 ( 50 | REM : count number of running instances 51 | if [!firstArg!] == ["NONE"] for /F "delims=~=" %%n in ('wmic process get Commandline 2^>NUL ^| find /I !program! ^| find /I /V "find" /C') do set /A "nbIs=%%n" 52 | if not [!firstArg!] == ["NONE"] for /F "delims=~=" %%n in ('wmic process get Commandline 2^>NUL ^| find /I !program! ^| find /I !firstArg! ^| find /I /V "find" /C') do set /A "nbIs=%%n" 53 | 54 | set cmd=!command:"=! 55 | 56 | REM : start the program if it is not already running 57 | if !nbIs! EQU 0 wscript /nologo !Start! !cmd:'="! 58 | ) 59 | ) 60 | exit !ERRORLEVEL! 61 | 62 | goto:eof 63 | REM : ------------------------------------------------------------------ 64 | 65 | REM : ------------------------------------------------------------------ 66 | REM : functions 67 | 68 | :cleanHostLogFile 69 | REM : pattern to ignore in log file 70 | set "pat=%~1" 71 | set "logFileTmp="!logFile:"=!.bfw_tmp"" 72 | if exist !logFileTmp! ( 73 | del /F !logFile! > NUL 2>&1 74 | move /Y !logFileTmp! !logFile! > NUL 2>&1 75 | ) 76 | 77 | type !logFile! | find /I /V "!pat!" > !logFileTmp! 78 | 79 | del /F /S !logFile! > NUL 2>&1 80 | move /Y !logFileTmp! !logFile! > NUL 2>&1 81 | 82 | goto:eof 83 | REM : ------------------------------------------------------------------ 84 | 85 | :resolveVenv 86 | set "value="%~1"" 87 | set "resolved=%value:"=%" 88 | 89 | REM : check if value is a path 90 | echo %resolved% | find ":" > NUL && ( 91 | REM : check if it is only a device letter issue (in case of portable library) 92 | set "tmpStr='!drive!%resolved:~3%" 93 | set "newLocation=!tmpStr:'="!" 94 | if exist !newLocation! set "resolved=!tmpStr!" 95 | ) 96 | 97 | set "%2=!resolved!" 98 | goto:eof 99 | REM : ------------------------------------------------------------------ 100 | 101 | 102 | 103 | -------------------------------------------------------------------------------- /tools/monitorBatchFw.bat: -------------------------------------------------------------------------------- 1 | @echo off 2 | setlocal EnableExtensions 3 | title Monitor BatchFw Launch 4 | REM : ------------------------------------------------------------------ 5 | REM : main 6 | 7 | setlocal EnableDelayedExpansion 8 | color 4F 9 | 10 | set "THIS_SCRIPT=%~0" 11 | 12 | REM : directory of this script 13 | set "SCRIPT_FOLDER="%~dp0"" && set "BFW_TOOLS_PATH=!SCRIPT_FOLDER:\"="!" 14 | 15 | for %%a in (!BFW_TOOLS_PATH!) do set "parentFolder="%%~dpa"" 16 | set "BFW_PATH=!parentFolder:~0,-2!"" 17 | for %%a in (!BFW_PATH!) do set "parentFolder="%%~dpa"" 18 | for %%a in (!BFW_PATH!) do set "drive=%%~da" 19 | set "GAMES_FOLDER=!parentFolder!" 20 | if not [!GAMES_FOLDER!] == ["!drive!\"] set "GAMES_FOLDER=!parentFolder:~0,-2!"" 21 | 22 | REM : basename of GAME FOLDER PATH (used to name shorcut) 23 | for /F "delims=~" %%i in (!GAMES_FOLDER!) do set "GAMES_FOLDER_NAME=%%~nxi" 24 | 25 | set "BFW_RESOURCES_PATH="!BFW_PATH:"=!\resources"" 26 | set "BFW_LOGS_PATH="!BFW_PATH:"=!\logs"" 27 | 28 | set "batchFwLog="!BFW_LOGS_PATH:"=!\logs\BatchFwLog.txt"" 29 | set "MessageBox="!BFW_RESOURCES_PATH:"=!\vbs\MessageBox.vbs"" 30 | set "Start="!BFW_RESOURCES_PATH:"=!\vbs\Start.vbs"" 31 | 32 | set "killBatchFw="!BFW_TOOLS_PATH:"=!\killBatchFw.bat"" 33 | 34 | REM : timeout value in seconds 35 | set /A "timeOut=180" 36 | 37 | REM : duration value in seconds 38 | set /A "duration=0" 39 | set /A "wizardLaunched=0" 40 | 41 | REM : monitor LaunchGame.bat until cemu is launched 42 | set "logFileTmp="!TMP:"=!\BatchFw_monitor_process.list"" 43 | 44 | :waitingLoopProcesses 45 | timeout /T 1 > NUL 2>&1 46 | wmic process get Commandline 2>NUL | find ".exe" | find /I /V "wmic" | find /I /V "find" > !logFileTmp! 47 | type !logFileTmp! | find /I "LaunchGame" > NUL 2>&1 && ( 48 | 49 | REM : set BatchFw processes to priority to high 50 | wmic process where "CommandLine like '%%!GAMES_FOLDER_NAME!%%'" call setpriority 128 > NUL 2>&1 51 | 52 | REM : if wizard is running, double timmeout 53 | if !wizardLaunched! EQU 0 type !batchFwLog! | find /I "wizardFirstSaving.bat" > NUL 2>&1 && set /A "wizardLaunched=0" & set /A "timeOut=360" & goto:waitingLoopProcesses 54 | 55 | REM : if rar is running, don't count 56 | type !logFileTmp! | find /I "rar.exe" | find /I /V "winRar" |find /I "_BatchFw_Graphic_Packs" > NUL 2>&1 && goto:waitingLoopProcesses 57 | 58 | REM : monitor Cemu launch 59 | type !logFileTmp! | find /I "cemu.exe" > NUL 2>&1 && set /A "duration=-1" 60 | 61 | if !duration! GEQ 0 set /A "duration+=1" 62 | if !duration! GTR !timeOut! call:askToKill 63 | goto:waitingLoopProcesses 64 | ) 65 | del /F !logFileTmp! > NUL 2>&1 & 66 | exit 0 67 | 68 | REM : ------------------------------------------------------------------ 69 | REM : functions 70 | 71 | :askToKill 72 | 73 | type !logFileTmp! | find /I "GraphicPacks.bat" | find /I "create" > NUL 2>&1 && ( 74 | 75 | REM : warn user with a retry/cancel msgBox 76 | wscript /nologo !Start! !MessageBox! "GFX packs completion is still running. Wait 60sec more. If you want to kill all processes anyway, use .\BatchFw\Kill BatchFw Processes.lnk" 77 | set /A "duration-=60" 78 | goto:eof 79 | ) 80 | 81 | REM : warn user with a retry/cancel msgBox 82 | !MessageBox! "Hum... BatchFw is taken too much time. Killing it ? Wait a little longer [Yes] or kill it [No] ?" 4100 83 | if !ERRORLEVEL! EQU 6 set /A "duration-=30" && goto:eof 84 | del /F !logFileTmp! > NUL 2>&1 85 | call !killBatchFw! & exit 1 86 | 87 | goto:eof -------------------------------------------------------------------------------- /tools/multiply.bat: -------------------------------------------------------------------------------- 1 | @echo off 2 | color f0 3 | setlocal EnableExtensions 4 | REM : ------------------------------------------------------------------ 5 | REM : This script multiply numbers (float or integer) with no limitations 6 | 7 | setlocal EnableDelayedExpansion 8 | call:setCharSet 9 | 10 | REM : checking arguments 11 | set /A "nbArgs=0" 12 | :continue 13 | if "%~1"=="" goto:end 14 | set "args[%nbArgs%]=%~1" 15 | set /A "nbArgs +=1" 16 | shift 17 | goto:continue 18 | :end 19 | 20 | if !nbArgs! EQU 0 ( 21 | echo ERROR ^: on arguments passed ^! 22 | echo SYNTAXE ^: "%~0" number1 number2 23 | pause 24 | exit /b 99 25 | ) 26 | 27 | REM : Args 28 | set "str1=!args[0]!" 29 | set "str2=!args[1]!" 30 | 31 | REM : Args checks 32 | echo !str1! | findstr /R "^[0-9.]*.$" > NUL 2>&1 && goto:str1Ok 33 | echo ERROR^:^(!str1!^) is not a number using ^. as decimals delimiter 34 | exit /b 1 35 | 36 | :str1Ok 37 | echo !str2! | findstr /R "^[0-9.]*.$" > NUL 2>&1 && goto:str2Ok 38 | echo ERROR^:^(!str2!^) is not a number using ^. as decimals delimiter 39 | exit /b 2 40 | 41 | :str2Ok 42 | 43 | REM : compute length and dot rank in the string 44 | call:getLengthAndDotPositionFloat !str1! length1 dotRank1 45 | call:getLengthAndDotPositionFloat !str2! length2 dotRank2 46 | 47 | REM : position of the decimal part in the result 48 | set /A "nbDec=0" 49 | if not ["!dotRank1!"] == [""] set /A "nbDec=length1-1-!dotRank1!" 50 | if not ["!dotRank2!"] == [""] set /A "nbDec=nbDec+length2-1-!dotRank2!" 51 | 52 | REM : remove the dot and compute the product 53 | set "int1=!str1:.=!" 54 | set "int2=!str2:.=!" 55 | call:multiply int1 int2 prodStr 56 | 57 | REM : get the length of the product string 58 | call:strLength !prodStr! length 59 | 60 | set /A "decPartSize=length-nbDec" 61 | REM : built the result 62 | if !nbDec! EQU 0 ( 63 | set result=!prodStr! 64 | ) else ( 65 | set "result=!prodStr:~0,%decPartSize%!.!prodStr:~%decPartSize%,%nbDec%!" 66 | ) 67 | 68 | echo !result! 69 | 70 | exit /b 0 71 | 72 | REM : ------------------------------------------------------------------ 73 | REM : functions 74 | REM : ------------------------------------------------------------------ 75 | 76 | REM : Get the length of a string 77 | :strLength 78 | Set "s=#%~1" 79 | Set "len=0" 80 | For %%N in (4096 2048 1024 512 256 128 64 32 16 8 4 2 1) do ( 81 | if "!s:~%%N,1!" neq "" ( 82 | set /a "len+=%%N" 83 | set "s=!s:~%%N!" 84 | ) 85 | ) 86 | set /A "%2=%len%" 87 | goto:eof 88 | 89 | REM : Get the length and the dot position in a string 90 | :getLengthAndDotPositionFloat 91 | 92 | set "str=%~1" 93 | 94 | REM : dot position in str 95 | set "dotPos=" 96 | REM : str length 97 | set /A "len=-1" 98 | 99 | :loop 100 | set /A "len=len+1" 101 | set "subStr=!str:~%len%,1!" 102 | if defined subStr ( 103 | if ["%subStr%"] == ["."] set /A "dotPos=!len!" 104 | goto:loop 105 | ) 106 | 107 | REM : outputs 108 | set "%2=!len!" 109 | set "%3=!dotPos!" 110 | 111 | goto:eof 112 | 113 | REM : ------------------------------------------------------------------ 114 | REM : Multiply long integer (bypass 32bits limitation) 115 | :multiply 116 | 117 | set _num1=!%1! 118 | set _num2=!%2! 119 | set _result=%3 120 | 121 | for /l %%a in (1,1,2) do ( 122 | for /l %%b in (0,1,9) do ( 123 | set _num%%a=!_num%%a:%%b=%%b ! 124 | ) 125 | ) 126 | for %%a in (!_num1!) do set /a _num1cnt+=1 & set _!_num1cnt!_num1=%%a 127 | for %%a in (!_num2!) do set /a _num2cnt+=1 & set _!_num2cnt!_num2=%%a 128 | if !_num1cnt! equ 1 if !_num2cnt! equ 1 ( 129 | set /a !_result!=!_num1! * !_num2! 130 | goto :eof 131 | ) 132 | for /l %%b in (!_num2cnt!,-1,1) do ( 133 | 134 | for /l %%a in (!_num1cnt!,-1,1) do ( 135 | set /a _tmp=!_%%b_num2! * !_%%a_num1! !_plus! !_co! 136 | set _co= 137 | set _plus= 138 | if !_tmp! gtr 9 set _co=!_tmp:~0,1!& set _tmp=!_tmp:~-1!& set _plus=+ 139 | set _num3_%%b=!_num3_%%b!!_spc!!_tmp! 140 | set _spc= 141 | set _tmp= 142 | ) 143 | if defined _co set _num3_%%b=!_num3_%%b! !_co!& set _co=& set _plus= 144 | set _num3_%%b=!_zero!!_num3_%%b! 145 | set _zero=0!_spc1!!_zero! 146 | set _spc1= 147 | for %%a in (!_num3_%%b!) do ( 148 | set /a _cnt+=1 149 | for %%c in (!_cnt!) do set _num4_%%c=!_num4_%%c!%%a+ 150 | ) 151 | set _cnt= 152 | ) 153 | for /f %%a in ('set _num4') do set /a _colcnt+=1 154 | for /l %%a in (1,1,!_colcnt!) do set /a _num5_%%a=!_num4_%%a:~0,-1! 155 | for /l %%a in (1,1,!_colcnt!) do ( 156 | if defined _co set /a _num5_%%a=!_num5_%%a! + !_co! 157 | set _co= 158 | if !_num5_%%a! gtr 9 ( 159 | set _co=!_num5_%%a:~0,-1! 160 | set _num6=!_num5_%%a:~-1!!_num6! 161 | ) else ( 162 | set _num6=!_num5_%%a!!_num6! 163 | ) 164 | set !_result!=!_co!!_num6! 165 | ) 166 | 167 | goto:eof 168 | REM : ------------------------------------------------------------------ 169 | 170 | REM : function to get and set char set code for current host 171 | :setCharSet 172 | 173 | REM : get charset code for current HOST 174 | set "CHARSET=NOT_FOUND" 175 | for /F "tokens=2 delims=~=" %%f in ('wmic os get codeset /value 2^>NUL ^| find "="') do set "CHARSET=%%f" 176 | 177 | if ["%CHARSET%"] == ["NOT_FOUND"] ( 178 | echo Host char codeSet not found ^?^, exiting 1 179 | exit /b 9 180 | ) 181 | REM : set char code set, output to host log file 182 | 183 | chcp %CHARSET% > NUL 2>&1 184 | 185 | goto:eof 186 | REM : ------------------------------------------------------------------ 187 | 188 | -------------------------------------------------------------------------------- /tools/progressBar.bat: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Laf111/CEMU-Batch-Framework/e47a1bdf897d571f75f154a42a4fa8c12b412cec/tools/progressBar.bat -------------------------------------------------------------------------------- /tools/restoreBfwDefaultSettings.bat: -------------------------------------------------------------------------------- 1 | @echo off 2 | setlocal EnableExtensions 3 | REM : ------------------------------------------------------------------ 4 | REM : main 5 | setlocal EnableDelayedExpansion 6 | color 4F 7 | 8 | title Restore BacthFw factory settings 9 | 10 | set "THIS_SCRIPT=%~0" 11 | 12 | REM : checking THIS_SCRIPT path 13 | call:checkPathForDos "!THIS_SCRIPT!" > NUL 2>&1 14 | set /A "cr=!ERRORLEVEL!" 15 | if !cr! NEQ 0 ( 16 | echo ERROR ^: Remove DOS reserved characters from the path "!THIS_SCRIPT!" ^(such as ^&^, %% or ^^!^)^, cr=!cr! 17 | pause 18 | exit 1 19 | ) 20 | 21 | REM : directory of this script 22 | 23 | set "SCRIPT_FOLDER="%~dp0"" && set "BFW_TOOLS_PATH=!SCRIPT_FOLDER:\"="!" 24 | 25 | for %%a in (!BFW_TOOLS_PATH!) do set "parentFolder="%%~dpa"" 26 | set "BFW_PATH=!parentFolder:~0,-2!"" 27 | for %%a in (!BFW_PATH!) do set "parentFolder="%%~dpa"" 28 | for %%a in (!BFW_PATH!) do set "drive=%%~da" 29 | set "GAMES_FOLDER=!parentFolder!" 30 | if not [!GAMES_FOLDER!] == ["!drive!\"] set "GAMES_FOLDER=!parentFolder:~0,-2!"" 31 | 32 | set "BFW_RESOURCES_PATH="!BFW_PATH:"=!\resources"" 33 | set "StartHidden="!BFW_RESOURCES_PATH:"=!\vbs\StartHidden.vbs"" 34 | set "StartMaximized="!BFW_RESOURCES_PATH:"=!\vbs\StartMaximized.vbs"" 35 | set "StartMaximizedWait="!BFW_RESOURCES_PATH:"=!\vbs\StartMaximizedWait.vbs"" 36 | 37 | set "BFW_LOGS="!BFW_PATH:"=!\logs"" 38 | set "logFile="!BFW_LOGS:"=!\Host_!USERDOMAIN!.log"" 39 | 40 | REM : checking GAMES_FOLDER folder 41 | call:checkPathForDos !GAMES_FOLDER! 42 | 43 | REM : set current char codeset 44 | call:setCharSet 45 | 46 | REM : cd to GAMES_FOLDER 47 | pushd !GAMES_FOLDER! 48 | 49 | echo ========================================================= 50 | echo Reset BatchFw to factory settings ^? 51 | echo ========================================================= 52 | 53 | echo Launching in 30s 54 | echo ^(y^) ^: launch now 55 | echo ^(n^) ^: cancel 56 | echo --------------------------------------------------------- 57 | call:getUserInput "Enter your choice ? : " "y,n" ANSWER 30 58 | if [!ANSWER!] == ["n"] ( 59 | REM : Cancelling 60 | choice /C y /T 2 /D y /N /M "Cancelled by user, exiting in 2s" 61 | goto:eof 62 | ) 63 | cls 64 | 65 | for /F "tokens=2 delims=~=" %%i in ('type !logFile! ^| find "Create " 2^>NUL') do set "WIIU_GAMES_FOLDER="%%i"" 66 | 67 | echo ^> Deleting !BFW_LOGS! ^.^.^. 68 | rmdir /Q /S !BFW_LOGS! 69 | 70 | mkdir !BFW_LOGS! > NUL 2>&1 71 | pushd !GAMES_FOLDER! 72 | 73 | 74 | set "BFW_GP_FOLDER="!GAMES_FOLDER:"=!\_BatchFw_Graphic_Packs"" 75 | if exist !BFW_GP_FOLDER! ( 76 | rmdir /Q /S !BFW_GP_FOLDER! 77 | echo --------------------------------------------------------- 78 | echo ^> Delete graphic pack folder !BFW_GP_FOLDER! ^.^.^. 79 | ) 80 | 81 | if exist !WIIU_GAMES_FOLDER! ( 82 | rmdir /Q /S !WIIU_GAMES_FOLDER! > NUL 2>&1 83 | echo --------------------------------------------------------- 84 | echo ^> Delete shortcuts created ^.^.^. 85 | ) 86 | 87 | 88 | set "bfrf="!BFW_PATH:"=!\BatchFw_readme.txt"" 89 | if exist !bfrf! ( 90 | echo --------------------------------------------------------- 91 | echo ^> Delete BatchFW_readme.txt ^.^.^. 92 | del /F !bfrf! > NUL 2>&1 93 | ) 94 | 95 | REM : convert all bat files to AINSI, remove trailling spaces 96 | set "fixBatFile="!BFW_TOOLS_PATH:"=!\fixBatFiles.bat"" 97 | call !fixBatFile! 98 | 99 | echo ========================================================= 100 | echo Done 101 | echo ######################################################### 102 | 103 | 104 | echo Launching setup.bat in 6s 105 | timeout /T 6 > NUL 2>&1 106 | set "setup="!BFW_PATH:"=!\setup.bat"" 107 | wscript /nologo !StartMaximized! !setup! 108 | 109 | endlocal 110 | exit /b 0 111 | 112 | goto:eof 113 | 114 | REM : ------------------------------------------------------------------ 115 | 116 | 117 | REM : ------------------------------------------------------------------ 118 | REM : functions 119 | 120 | :checkPathForDos 121 | 122 | set "toCheck=%1" 123 | 124 | REM : if implicit expansion failed (when calling this script) 125 | if ["!toCheck!"] == [""] ( 126 | echo Remove specials characters from %1 ^(such as ^&,^(,^),^!^)^, exiting 13 127 | exit /b 13 128 | ) 129 | 130 | REM : try to resolve 131 | if not exist !toCheck! ( 132 | echo This path ^(!toCheck!^) is not compatible with DOS^. Remove specials characters from this path ^(such as ^&,^(,^),^!^)^, exiting 11 133 | exit /b 11 134 | ) 135 | 136 | REM : try to list 137 | dir !toCheck! > NUL 2>&1 138 | if !ERRORLEVEL! NEQ 0 ( 139 | echo This path ^(!toCheck!^) is not compatible with DOS^. Remove specials characters from this path ^(such as ^&,^(,^),^!^)^, exiting 12 140 | exit /b 12 141 | ) 142 | 143 | exit /b 0 144 | goto:eof 145 | REM : ------------------------------------------------------------------ 146 | 147 | REM : function to get user input in allowed valuesList (beginning with default timeout value) from question and return the choice 148 | :getUserInput 149 | 150 | REM : arg1 = question 151 | set "question="%~1"" 152 | REM : arg2 = valuesList 153 | set "valuesList=%~2" 154 | REM : arg3 = return of the function (user input value) 155 | REM : arg4 = timeOutValue (optional : if given set 1st value as default value after timeOutValue seconds) 156 | set "timeOutValue=%~4" 157 | 158 | set choiceValues=%valuesList:,=% 159 | set defaultTimeOutValue=%valuesList:~0,1% 160 | 161 | REM : building choice command 162 | if ["%timeOutValue%"] == [""] ( 163 | set choiceCmd=choice /C %choiceValues% /CS /N /M !question! 164 | ) else ( 165 | set choiceCmd=choice /C %choiceValues% /CS /N /T %timeOutValue% /D %defaultTimeOutValue% /M !question! 166 | ) 167 | 168 | REM : launching and get return code 169 | !choiceCmd! 170 | set /A "cr=!ERRORLEVEL!" 171 | 172 | set j=1 173 | for %%i in ("%valuesList:,=" "%") do ( 174 | 175 | if [%cr%] == [!j!] ( 176 | REM : value found , return function value 177 | 178 | set "%3=%%i" 179 | goto:eof 180 | ) 181 | set /A j+=1 182 | ) 183 | 184 | goto:eof 185 | REM : ------------------------------------------------------------------ 186 | 187 | 188 | REM : function to get and set char set code for current host 189 | :setCharSet 190 | 191 | REM : get charset code for current HOST 192 | set "CHARSET=NOT_FOUND" 193 | for /F "tokens=2 delims==" %%f in ('wmic os get codeset /value 2^>NUL ^| find "="') do set "CHARSET=%%f" 194 | 195 | if ["%CHARSET%"] == ["NOT_FOUND"] ( 196 | echo Host char codeSet not found in %0 ^? 197 | pause 198 | exit /b 9 199 | ) 200 | REM : set char code set, output to host log file 201 | 202 | chcp %CHARSET% > NUL 2>&1 203 | call:log2HostFile "charCodeSet=%CHARSET%" 204 | 205 | goto:eof 206 | REM : ------------------------------------------------------------------ 207 | 208 | 209 | REM : function to log info for current host 210 | :log2HostFile 211 | REM : arg1 = msg 212 | set "msg=%~1" 213 | 214 | if not exist !logFile! ( 215 | set "logFolder="!BFW_PATH:"=!\logs"" 216 | if not exist !logFolder! mkdir !logFolder! > NUL 2>&1 217 | goto:logMsg2HostFile 218 | ) 219 | REM : check if the message is not already entierely present 220 | for /F %%i in ('type !logFile! ^| find /I "!msg!"') do goto:eof 221 | :logMsg2HostFile 222 | echo !msg! >> !logFile! 223 | 224 | goto:eof 225 | REM : ------------------------------------------------------------------ 226 | -------------------------------------------------------------------------------- /tools/setWiiuAccountToUsers.bat: -------------------------------------------------------------------------------- 1 | @echo off 2 | setlocal EnableExtensions 3 | REM : ------------------------------------------------------------------ 4 | REM : main 5 | 6 | setlocal EnableDelayedExpansion 7 | 8 | color 4F 9 | 10 | set "THIS_SCRIPT=%~0" 11 | 12 | REM : directory of this script 13 | set "SCRIPT_FOLDER="%~dp0"" && set "BFW_TOOLS_PATH=!SCRIPT_FOLDER:\"="!" 14 | 15 | for %%a in (!BFW_TOOLS_PATH!) do set "parentFolder="%%~dpa"" 16 | set "BFW_PATH=!parentFolder:~0,-2!"" 17 | for %%a in (!BFW_PATH!) do set "parentFolder="%%~dpa"" 18 | for %%a in (!BFW_PATH!) do set "drive=%%~da" 19 | set "GAMES_FOLDER=!parentFolder!" 20 | if not [!GAMES_FOLDER!] == ["!drive!\"] set "GAMES_FOLDER=!parentFolder:~0,-2!"" 21 | 22 | set "BFW_RESOURCES_PATH="!BFW_PATH:"=!\resources"" 23 | set "fnrPath="!BFW_RESOURCES_PATH:"=!\fnr.exe"" 24 | set "StartHiddenWait="!BFW_RESOURCES_PATH:"=!\vbs\StartHiddenWait.vbs"" 25 | 26 | set "logFile="!BFW_PATH:"=!\logs\Host_!USERDOMAIN!.log"" 27 | 28 | REM : set current char codeset 29 | call:setCharSet 30 | 31 | REM : create folders 32 | set "BFW_WIIU_FOLDER="!GAMES_FOLDER:"=!\_BatchFw_WiiU"" 33 | set "BFW_ONLINE_FOLDER="!BFW_WIIU_FOLDER:"=!\OnlineFiles"" 34 | 35 | set "WIIU_ACCOUNTS_FOLDER="!BFW_ONLINE_FOLDER:"=!\wiiuAccounts\usr\save\system\act"" 36 | if not exist !WIIU_ACCOUNTS_FOLDER! ( 37 | echo ERROR^: !WIIU_ACCOUNTS_FOLDER! does not exist ^!^ 38 | echo Use Wii-U Games^\Wii-U^\Get online files^.lnk 39 | echo or Wii-U Games^\Wii-U^\Scan my Wii-U^.lnk 40 | echo before this script 41 | pause 42 | exit 99 43 | ) 44 | cls 45 | 46 | echo ========================================================= 47 | echo Associate BatchFw^'s users to Wii-U accounts 48 | echo ========================================================= 49 | 50 | REM : display BatchFw users list 51 | set "USERSARRAY=" 52 | set /A "nbUsers=0" 53 | for /F "tokens=2 delims=~=" %%i in ('type !logFile! ^| find /I "USER_REGISTERED" 2^>NUL') do ( 54 | set "USERSARRAY[!nbUsers!]=%%i" 55 | set /A "nbUsers+=1" 56 | ) 57 | if !nbUsers! EQU 0 ( 58 | echo No users were found^!^. Please restore BatchFw factory settings 59 | pause 60 | exit 50 61 | ) 62 | set /A "nbUsers-=1" 63 | 64 | echo ========================================================= 65 | 66 | set "usersFolderAccount="!BFW_ONLINE_FOLDER:"=!\usersAccounts"" 67 | if exist !usersFolderAccount! rmdir /Q /S !usersFolderAccount! 68 | mkdir !usersFolderAccount! > NUL 2>&1 69 | 70 | 71 | REM : loop on all 800000XX folders found 72 | pushd !WIIU_ACCOUNTS_FOLDER! 73 | for /F "delims=~" %%d in ('dir /B /A:D 80* 2^>NUL') do ( 74 | 75 | set "af="!WIIU_ACCOUNTS_FOLDER:"=!\%%d\account.dat"" 76 | 77 | for /F "delims=~= tokens=2" %%n in ('type !af! ^| find /I "IsPasswordCacheEnabled=0"') do ( 78 | echo WARNING^: this account seems to not have "Save password" option checked ^(auto login^) ^! 79 | echo it might be unusable with CEMU 80 | echo. 81 | echo Check "Save password" option for %%d account on the Wii-U and relaunch this script 82 | echo. 83 | ) 84 | 85 | REM : get AccountId from account.dat 86 | set "accId=NONE" 87 | for /F "delims=~= tokens=2" %%n in ('type !af! ^| find /I "AccountId="') do set "accId=%%n" 88 | if ["%accId%"] == ["NONE"] ( 89 | echo ERROR^: fail to parse !af! 90 | pause 91 | ) 92 | REM : Ask for Batch's user 93 | echo Which batchFw^'s user use the accountId 94 | echo ^> !accId! 95 | echo on the Wii-U ^(folder^'s name is %%d^) ^? 96 | echo. 97 | 98 | set "user=NONE" 99 | call:getUser user 100 | 101 | REM : copy the file 102 | set "uf="!usersFolderAccount:"=!\!user!%%d.dat"" 103 | 104 | copy /Y !af! !uf! > NUL 2>&1 105 | echo saving \%%d\account.dat to !uf! 106 | echo --------------------------------------------------------- 107 | ) 108 | echo ========================================================= 109 | echo if you had mistaken^, relaunch this script to change the 110 | echo association 111 | echo. 112 | echo if an account was not listed^, you might have to relaunch 113 | echo Wii-U Games\Wii-U\Get online files^.lnk 114 | echo to synchronize folders with your Wii-U first 115 | 116 | pause 117 | 118 | exit /b 0 119 | 120 | goto:eof 121 | REM : ------------------------------------------------------------------ 122 | 123 | 124 | 125 | REM : ------------------------------------------------------------------ 126 | REM : functions 127 | 128 | :getUser 129 | 130 | for /L %%i in (0,1,!nbUsers!) do echo %%i ^: !USERSARRAY[%%i]! 131 | echo. 132 | :askUser 133 | set /P "num=Enter the BatchFw user's number [0, !nbUsers!] : " 134 | 135 | echo %num% | findStr /R /V "[0-9]" > NUL 2>&1 && goto:askUser 136 | 137 | if %num% LSS 0 goto:askUser 138 | if %num% GTR %nbUsers% goto:askUser 139 | 140 | set "%1=!USERSARRAY[%num%]!" 141 | goto:eof 142 | REM : ------------------------------------------------------------------ 143 | 144 | REM : function to get and set char set code for current host 145 | :setCharSet 146 | 147 | REM : get charset code for current HOST 148 | set "CHARSET=NOT_FOUND" 149 | for /F "tokens=2 delims=~=" %%f in ('wmic os get codeset /value 2^>NUL ^| find "="') do set "CHARSET=%%f" 150 | 151 | if ["%CHARSET%"] == ["NOT_FOUND"] ( 152 | echo Host char codeSet not found in %0 ^? 153 | timeout /t 8 > NUL 2>&1 154 | exit /b 9 155 | ) 156 | REM : set char code set, output to host log file 157 | 158 | chcp %CHARSET% > NUL 2>&1 159 | 160 | REM : get locale for current HOST 161 | set "L0CALE_CODE=NOT_FOUND" 162 | for /F "tokens=2 delims=~=" %%f in ('wmic path Win32_OperatingSystem get Locale /value 2^>NUL ^| find "="') do set "L0CALE_CODE=%%f" 163 | 164 | goto:eof 165 | REM : ------------------------------------------------------------------ 166 | -------------------------------------------------------------------------------- /tools/stopThirdPartySoftware.bat: -------------------------------------------------------------------------------- 1 | @echo off 2 | setlocal EnableExtensions 3 | title Stop BatchFw third party software 4 | REM : ------------------------------------------------------------------ 5 | REM : main 6 | 7 | setlocal EnableDelayedExpansion 8 | rem color 4F 9 | color F0 10 | 11 | set "THIS_SCRIPT=%~0" 12 | 13 | REM : directory of this script 14 | set "SCRIPT_FOLDER="%~dp0"" && set "BFW_TOOLS_PATH=!SCRIPT_FOLDER:\"="!" 15 | 16 | for %%a in (!BFW_TOOLS_PATH!) do set "parentFolder="%%~dpa"" 17 | set "BFW_PATH=!parentFolder:~0,-2!"" 18 | 19 | set "BFW_RESOURCES_PATH="!BFW_PATH:"=!\resources"" 20 | 21 | set "MessageBox="!BFW_RESOURCES_PATH:"=!\vbs\MessageBox.vbs"" 22 | 23 | set "logFile="!BFW_PATH:"=!\logs\Host_!USERDOMAIN!.log"" 24 | 25 | set /A "nbIs=0" 26 | for /F "tokens=* delims=~" %%i in ('type !logFile! ^| find /I "TO_BE_LAUNCHED" 2^>NUL') do ( 27 | echo line read ^: %%i 28 | call:closeSoftware "%%i" 29 | ) 30 | 31 | exit !ERRORLEVEL! 32 | 33 | goto:eof 34 | REM : ------------------------------------------------------------------ 35 | 36 | REM : ------------------------------------------------------------------ 37 | REM : functions 38 | 39 | 40 | :closeSoftware 41 | 42 | set "line="%~1"" 43 | 44 | for /F "tokens=3 delims=~@" %%j in (!line!) do set "whatTodo=%%j" 45 | 46 | echo Close = !whatTodo! 47 | if ["!whatTodo!"] == ["N"] goto:eof 48 | 49 | for /F "tokens=2 delims=~@" %%j in (!line!) do set "command="%%j"" 50 | 51 | 52 | set "program="NONE"" 53 | set "firstArg="NONE"" 54 | 55 | REM : resolve venv for search 56 | for /F "tokens=1 delims=~'" %%j in (!command!) do set "program="%%j"" 57 | for /F "tokens=3 delims=~'" %%j in (!command!) do set "firstArg="%%j"" 58 | 59 | echo program = !program! 60 | echo firstArg = !firstArg! 61 | 62 | if not [!program!] == ["NONE"] if not exist !program! ( 63 | call:cleanHostLogFile !program! 64 | !MessageBox! "WARNING software to launch before CEMU !program! does not exist anymore in host log file^, deleting this entry^!" 4144 65 | set /A "nbIs=99" 66 | ) 67 | if !nbIs! NEQ 99 ( 68 | REM : count number of running instances 69 | if [!firstArg!] == ["NONE"] for /F "delims==" %%n in ('wmic process get Commandline 2^>NUL ^| find /I !program! ^| find /I /V "find" /C') do set /A "nbIs=%%n" 70 | if not [!firstArg!] == ["NONE"] for /F "delims==" %%n in ('wmic process get Commandline 2^>NUL ^| find /I !program! ^| find /I !firstArg! ^| find /I /V "find" /C') do set /A "nbIs=%%n" 71 | 72 | echo nbIs=!nbIs! 73 | 74 | REM : basename of GAME FOLDER PATH (used to name shorcut) 75 | for /F "delims=~" %%i in (!program!) do set "exe=%%~nxi" 76 | for /F "delims=~" %%i in (!firstArg!) do set "argPiece=%%~nxi" 77 | 78 | REM : stop the program if it is not already running 79 | if !nbIs! NEQ 0 if [!firstArg!] == ["NONE"] wmic process where "Name like '!exe!'" call terminate 2>NUL && exit 0 80 | if !nbIs! NEQ 0 if not [!firstArg!] == ["NONE"] wmic process where "Name like '!exe!' and CommandLine like '%%!argPiece!%%'" call terminate 2>NUL && exit 0 81 | 82 | ) 83 | 84 | goto:eof 85 | REM : ------------------------------------------------------------------ 86 | -------------------------------------------------------------------------------- /tools/updateGameStats.bat: -------------------------------------------------------------------------------- 1 | @echo off 2 | setlocal EnableExtensions 3 | REM : ------------------------------------------------------------------ 4 | REM : main 5 | setlocal EnableDelayedExpansion 6 | color 4F 7 | 8 | REM : ------------------------------------------------------------------ 9 | REM : No verification is made regarding CEMU's version here 10 | REM : (game stats were added in CEMU V1.12.0 11 | 12 | 13 | set "THIS_SCRIPT=%~0" 14 | 15 | REM : directory of this script 16 | set "SCRIPT_FOLDER="%~dp0"" && set "BFW_TOOLS_PATH=!SCRIPT_FOLDER:\"="!" 17 | 18 | for %%a in (!BFW_TOOLS_PATH!) do set "parentFolder="%%~dpa"" 19 | set "BFW_PATH=!parentFolder:~0,-2!"" 20 | set "BFW_RESOURCES_PATH="!BFW_PATH:"=!\resources"" 21 | set "BFW_LOGS_PATH="!BFW_PATH:"=!\logs"" 22 | set "logFile="!BFW_PATH:"=!\logs\Host_!USERDOMAIN!.log"" 23 | set "MessageBox="!BFW_RESOURCES_PATH:"=!\vbs\MessageBox.vbs"" 24 | 25 | set "fnrPath="!BFW_RESOURCES_PATH:"=!\fnr.exe"" 26 | set "StartHiddenWait="!BFW_RESOURCES_PATH:"=!\vbs\StartHiddenWait.vbs"" 27 | 28 | REM : set current char codeset 29 | call:setCharSet 30 | 31 | REM : checking arguments 32 | set /A "nbArgs=0" 33 | :continue 34 | if "%~1"=="" goto:end 35 | set "args[%nbArgs%]="%~1"" 36 | set /A "nbArgs +=1" 37 | shift 38 | goto:continue 39 | :end 40 | 41 | if %nbArgs% NEQ 3 ( 42 | echo ERROR ^: on arguments passed ^! 43 | echo SYNTAXE ^: "!THIS_SCRIPT!" settingsSrcFile settingsTargetFile GameId 44 | echo given {%*} 45 | timeout /t 4 > NUL 2>&1 46 | exit 99 47 | ) 48 | 49 | REM : args 1 50 | set "csSrc=!args[0]!" 51 | if not exist !csSrc! ( 52 | echo ERROR ^: settingsSrcFile !csSrc:"=! not exist 53 | timeout /t 4 > NUL 2>&1 54 | exit 51 55 | ) 56 | set "csTgt=!args[1]!" 57 | if not exist !csTgt! ( 58 | echo ERROR ^: settingsTargetFile !csTgt:"=! not exist 59 | timeout /t 4 > NUL 2>&1 60 | exit 52 61 | ) 62 | set "GameId=!args[2]!" 63 | set "GameId=!GameId:"=!" 64 | 65 | REM : get DATE 66 | for /F "usebackq tokens=1,2 delims=~=" %%i in (`wmic os get LocalDateTime /VALUE 2^>NUL`) do if '.%%i.'=='.LocalDateTime.' set "ldt=%%j" 67 | set "ldt=%ldt:~0,4%-%ldt:~4,2%-%ldt:~6,2%_%ldt:~8,2%-%ldt:~10,2%-%ldt:~12,2%" 68 | set "DATE=%ldt%" 69 | 70 | echo ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 71 | echo Updating game with id !GameId! in !csTgt! 72 | echo using !csSrc! 73 | echo ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 74 | 75 | set "csTmp="!TMP:"=!\BfwSettings_!DATE!.xml"" 76 | echo temporary file ^: !csTmp! 77 | 78 | REM : if GameCache node exist in csTgt (CEMU >= 1.12.0) 79 | type !csTgt! | find /I "" > NUL 2>&1 && call:update 80 | 81 | 82 | exit /b !cr! 83 | goto:eof 84 | 85 | REM : ------------------------------------------------------------------ 86 | REM : functions 87 | 88 | 89 | REM : function to get and set char set code for current host 90 | :setCharSet 91 | 92 | REM : get charset code for current HOST 93 | set "CHARSET=NOT_FOUND" 94 | for /F "tokens=2 delims=~=" %%f in ('wmic os get codeset /value 2^>NUL ^| find "="') do set "CHARSET=%%f" 95 | 96 | if ["%CHARSET%"] == ["NOT_FOUND"] ( 97 | echo Host char codeSet not found in %0 ^? 98 | timeout /t 8 > NUL 2>&1 99 | exit /b 9 100 | ) 101 | REM : set char code set, output to host log file 102 | 103 | chcp %CHARSET% > NUL 2>&1 104 | 105 | REM : get locale for current HOST 106 | set "L0CALE_CODE=NOT_FOUND" 107 | for /F "tokens=2 delims=~=" %%f in ('wmic path Win32_OperatingSystem get Locale /value 2^>NUL ^| find "="') do set "L0CALE_CODE=%%f" 108 | 109 | goto:eof 110 | REM : ------------------------------------------------------------------ 111 | 112 | :update 113 | 114 | pushd !BFW_RESOURCES_PATH! 115 | echo csSrc=!csSrc! 116 | echo ------------------------------------------------------- 117 | type !csSrc! 118 | echo ------------------------------------------------------- 119 | echo ^"xml^.exe^" sel -t -c ^"^/^/GameCache^/Entry^[title_id=^'!GameId!^'^]^" !csSrc! 120 | 121 | REM : get game's stats 122 | "xml.exe" sel -t -c "//GameCache/Entry[title_id='!GameId!']" !csSrc! > !csTmp! 2>NUL 123 | 124 | echo csTmp=!csTmp! 125 | echo ------------------------------------------------------- 126 | type !csTmp! 127 | echo ------------------------------------------------------- 128 | set "node=" 129 | for /f "usebackq tokens=*" %%k in (!csTmp!) do ( 130 | set "node=!node!%%k" 131 | ) 132 | 133 | if ["!node!"] == [""] ( 134 | echo ERROR ^: no stats were found for !GameId! in !csSrc:"=! 135 | timeout /t 4 > NUL 2>&1 136 | exit 53 137 | ) 138 | 139 | REM : delete node in csTgt 140 | set "csTgtTmp=!csTgt:.xml=.bfw_tmp!" 141 | "xml.exe" ed -d "//GameCache/Entry[title_id='!GameId!']" !csTgt! > !csTgtTmp! 2>NUL 142 | 143 | echo ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 144 | echo Node ^: 145 | echo !node! 146 | 147 | "xml.exe" ed -s "//GameCache" -t elem -n "!node!" !csTgtTmp! > !csTmp! 2>NUL 148 | echo ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 149 | echo replacing in temporary file 150 | 151 | rem : replace in file 152 | set "BfwSettingsLog="!BFW_LOGS_PATH:"=!\fnr_BfwSettings.log"" 153 | 154 | wscript /nologo !StartHiddenWait! !fnrPath! --cl --dir !TMP! --fileMask "BfwSettings_!DATE!.xml" --find "<<" --replace "<" --logFile !BfwSettingsLog! 155 | wscript /nologo !StartHiddenWait! !fnrPath! --cl --dir !TMP! --fileMask "BfwSettings_!DATE!.xml" --find ">/>" --replace ">" --logFile !BfwSettingsLog! 156 | 157 | echo ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 158 | echo pretty indent !scTgt! 159 | 160 | xml fo -t !csTmp! > !csTgt! 161 | set /A "cr=%ERRORLEVEL%" 162 | echo ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 163 | 164 | if !cr! EQU 0 ( 165 | echo done 166 | goto:done 167 | ) 168 | 169 | REM : else check size 170 | for /F "tokens=*" %%a in (!csTgt!) do if %%~za NEQ 0 echo done & goto:done 171 | 172 | echo done with error ^! 173 | !MessageBox! "ERROR : when patching settings.xml. Restoring settings.xml backup, game stats computation ignored !" 4112 174 | echo see !csTmp! and !csTgtTmp! 175 | set "backup="!cs:"=!_bfw_old"" 176 | if exist !backup! del /F !cs! > NUL 2>&1 & move /Y !backup! !cs! > NUL 2>&1 177 | 178 | :done 179 | del /F !csTmp! > NUL 2>&1 180 | del /F !csTgtTmp! > NUL 2>&1 181 | del /F !BfwSettingsLog!> NUL 2>&1 182 | goto:eof 183 | REM : ------------------------------------------------------------------ 184 | -------------------------------------------------------------------------------- /tools/validateExtraGraphicPacksCreation.bat: -------------------------------------------------------------------------------- 1 | @echo off 2 | setlocal EnableExtensions 3 | REM : ------------------------------------------------------------------ 4 | REM : main 5 | 6 | setlocal EnableDelayedExpansion 7 | 8 | REM : directory of this script 9 | set "SCRIPT_FOLDER="%~dp0"" && set "BFW_TOOLS_PATH=!SCRIPT_FOLDER:\"="!" 10 | 11 | for %%a in (!BFW_TOOLS_PATH!) do set "parentFolder="%%~dpa"" 12 | set "BFW_PATH=!parentFolder:~0,-2!"" 13 | for %%a in (!BFW_PATH!) do set "parentFolder="%%~dpa"" 14 | for %%a in (!BFW_PATH!) do set "drive=%%~da" 15 | set "GAMES_FOLDER=!parentFolder!" 16 | if not [!GAMES_FOLDER!] == ["!drive!\"] set "GAMES_FOLDER=!parentFolder:~0,-2!"" 17 | 18 | set "BFW_GP_FOLDER="!GAMES_FOLDER:"=!\_BatchFw_Graphic_Packs"" 19 | set "BFW_RESOURCES_PATH="!BFW_PATH:"=!\resources"" 20 | 21 | set "glogFile="!BFW_PATH:"=!\logs\gamesLibrary.log"" 22 | 23 | REM : temporary folder for symlinks creation 24 | set "gfxpLinksFolder="!BFW_PATH:"=!\logs\gfxpLinksFolder"" 25 | 26 | if exist !gfxpLinksFolder! rmdir /Q /S !gfxpLinksFolder! > NUL 2>&1 27 | mkdir !gfxpLinksFolder! > NUL 2>&1 28 | 29 | REM : set current char codeset 30 | call:setCharSetOnly 31 | 32 | REM : search if launchGame.bat is not already running 33 | set /A "nbI=0" 34 | for /F "delims=~=" %%f in ('wmic process get Commandline 2^>NUL ^| find /I "cmd.exe" ^| find /I "launchGame.bat" ^| find /I /V "find" /C') do set /A "nbI=%%f" 35 | if %nbI% GEQ 1 ( 36 | echo ERROR^: launchGame^.bat is already^/still running^! If needed^, use ^'Wii-U Games^\BatchFw^\Kill BatchFw Processes^.lnk^'^. Aborting^! 37 | wmic process get Commandline 2>NUL | find /I "cmd.exe" | find /I "launchGame.bat" | find /I /V "find" 38 | pause 39 | exit 100 40 | ) 41 | 42 | cls 43 | echo ========================================================= 44 | echo Check last GFX packs version completion 45 | echo ========================================================= 46 | echo. 47 | 48 | REM : flag for creating old update and DLC paths 49 | set /A "buildOldUpdatePaths=1" 50 | 51 | REM : get the last version of GFX packs downloaded 52 | set "newVersion=NOT_FOUND" 53 | 54 | set "pat="!BFW_GP_FOLDER:"=!\graphicPacks*.doNotDelete"" 55 | 56 | REM : -------------------------------------------------------------------------------------- 57 | REM : get the github version of the last downloaded packs 58 | set "gpl="NOT_FOUND"" 59 | for /F "delims=~" %%a in ('dir /B !pat! 2^>NUL') do set "gpl="%%a"" 60 | if not [!gpl!] == ["NOT_FOUND"] set "zipLogFile="!BFW_GP_FOLDER:"=!\!gpl:"=!"" 61 | 62 | if [!gpl!] == ["NOT_FOUND"] ( 63 | echo WARNING ^: !pat! not found^, force extra pack creation ^! 64 | REM : create one 65 | set "dnd="!BFW_GP_FOLDER:"=!\graphicPacks703.doNotDelete"" 66 | echo. > !dnd! 67 | ) 68 | 69 | for /F "delims=~" %%i in (!zipLogFile!) do ( 70 | set "fileName=%%~nxi" 71 | set "newVersion=!fileName:.doNotDelete=!" 72 | ) 73 | echo ^> last github repository version downloaded ^: !newVersion! 74 | 75 | set "setup="!BFW_PATH:"=!\setup.bat"" 76 | 77 | set "strBfwMaxVgfxp=NONE" 78 | for /F "tokens=2 delims=~=" %%i in ('type !setup! ^| find /I "BFW_GFXP_VERSION=" 2^>NUL') do set "strBfwMaxVgfxp=%%i" 79 | set "strBfwMaxVgfxp=!strBfwMaxVgfxp:"=!" 80 | set /A "gfxPackVersion=!strBfwMaxVgfxp:V=!" 81 | 82 | echo ^> last version of GFX packs supported by BatchFw ^: !strBfwMaxVgfxp! 83 | 84 | REM : force GAME_GP_FOLDER 85 | set "GAME_GP_FOLDER=!gfxpLinksFolder!" 86 | 87 | pushd !BFW_GP_FOLDER! 88 | REM : V6 and up gfx packs 89 | for /F "delims=~" %%i in ('dir /B /S /A:D Graphics 2^> NUL') do ( 90 | call:treatGpLatestVersion "%%i" 91 | ) 92 | 93 | if exist !gfxpLinksFolder! del /F /S !gfxpLinksFolder! > NUL 2>&1 94 | 95 | pause 96 | goto:eof 97 | REM : ------------------------------------------------------------------ 98 | 99 | REM : ------------------------------------------------------------------ 100 | REM : functions 101 | 102 | 103 | REM : function to get and set char set code for current host 104 | :setCharSetOnly 105 | 106 | REM : get charset code for current HOST 107 | set "CHARSET=NOT_FOUND" 108 | for /F "tokens=2 delims=~=" %%f in ('wmic os get codeset /value 2^>NUL ^| find "="') do set "CHARSET=%%f" 109 | 110 | if ["%CHARSET%"] == ["NOT_FOUND"] ( 111 | echo Host char codeSet not found in %0 ^? 112 | pause 113 | exit /b 9 114 | ) 115 | REM : set char code set, output to host log file 116 | 117 | chcp %CHARSET% > NUL 2>&1 118 | 119 | goto:eof 120 | REM : ------------------------------------------------------------------ 121 | 122 | REM : function to log info for current host 123 | :log2GamesLibraryFile 124 | REM : arg1 = msg 125 | set "msg=%~1" 126 | 127 | if not exist !glogFile! ( 128 | set "logFolder="!BFW_PATH:"=!\logs"" 129 | if not exist !logFolder! mkdir !logFolder! > NUL 2>&1 130 | goto:logMsg2GamesLibraryFile 131 | ) 132 | 133 | REM : check if the message is not already entierely present 134 | for /F %%i in ('type !glogFile! ^| find /I "!msg!" 2^>NUL') do goto:eof 135 | 136 | :logMsg2GamesLibraryFile 137 | echo !msg! >> !glogFile! 138 | REM : sorting the log 139 | set "gLogFileTmp="!glogFile:"=!.bfw_tmp"" 140 | type !glogFile! | sort > !gLogFileTmp! 141 | del /F /S !glogFile! > NUL 2>&1 142 | move /Y !gLogFileTmp! !glogFile! > NUL 2>&1 143 | 144 | goto:eof 145 | REM : ------------------------------------------------------------------ 146 | 147 | :createPacks 148 | 149 | set "argSup=%gameName%" 150 | if ["%gameName%"] == [""] set "argSup=" 151 | 152 | echo Complete resolution graphic packs^.^.^. 153 | set "toBeLaunch="!BFW_TOOLS_PATH:"=!\createExtraGraphicPacks.bat"" 154 | call !toBeLaunch! !rulesFile! %titleId% 155 | 156 | echo Create BatchFW FPS cap graphic packs^.^.^. 157 | set "toBeLaunch="!BFW_TOOLS_PATH:"=!\createCapGraphicPacks.bat"" 158 | echo !toBeLaunch! !BFW_GP_FOLDER! !GAME_GP_FOLDER! !strBfwMaxVgfxp! %titleId% !argSup! 159 | 160 | call !toBeLaunch! !BFW_GP_FOLDER! !GAME_GP_FOLDER! !strBfwMaxVgfxp! %titleId% !argSup! 161 | 162 | goto:eof 163 | REM : ------------------------------------------------------------------ 164 | 165 | :treatGpLatestVersion 166 | set "graphicsFolder="%~1"" 167 | 168 | for %%a in (!graphicsFolder!) do set "parentFolder="%%~dpa"" 169 | set "gamePackFolder=!parentFolder:~0,-2!"" 170 | 171 | for /F "delims=~" %%i in (!gamePackFolder!) do set "gameName=%%~nxi" 172 | set "rulesFile="!graphicsFolder:"=!\rules.txt"" 173 | 174 | for /F "tokens=2 delims=~=," %%k in ('type !rulesFile! ^| find "titleIds"') do set "titleId=%%k" 175 | set "titleId=!titleId: =!" 176 | echo ######################################################### 177 | echo !gameName! [!titleId!] 178 | echo ######################################################### 179 | 180 | echo Found a resolution graphic pack ^: !rulesFile! 181 | call:createPacks 182 | 183 | REM : update !glogFile! (log2GamesLibraryFile does not add a already present message in !glogFile!) 184 | set "msg="!gameName! [%titleId%] graphic packs version=!newVersion!"" 185 | call:log2GamesLibraryFile !msg! 186 | 187 | goto:eof -------------------------------------------------------------------------------- /tools/wipeTracesOnHost.bat: -------------------------------------------------------------------------------- 1 | @echo off 2 | setlocal EnableExtensions 3 | REM : ------------------------------------------------------------------ 4 | REM : main 5 | 6 | setlocal EnableDelayedExpansion 7 | 8 | color 4F 9 | 10 | set "THIS_SCRIPT=%~0" 11 | 12 | REM : checking THIS_SCRIPT path 13 | call:checkPathForDos "!THIS_SCRIPT!" > NUL 2>&1 14 | set /A "cr=!ERRORLEVEL!" 15 | if !cr! NEQ 0 ( 16 | echo ERROR ^: Remove DOS reserved characters from the path "!THIS_SCRIPT!" ^(such as ^&^, %% or ^^!^)^, cr=!cr! 17 | pause 18 | exit 1 19 | ) 20 | 21 | REM : directory of this script 22 | set "SCRIPT_FOLDER="%~dp0"" && set "BFW_TOOLS_PATH=!SCRIPT_FOLDER:\"="!" 23 | 24 | for %%a in (!BFW_TOOLS_PATH!) do set "basename="%%~dpa"" 25 | set "BFW_PATH=!basename:~0,-2!"" 26 | 27 | set "logFile="!BFW_PATH:"=!\logs\Host_!USERDOMAIN!.log"" 28 | 29 | REM : set current char codeset 30 | call:setCharSet 31 | 32 | REM : search if launchGame.bat is not already running 33 | set /A "nbI=0" 34 | for /F "delims=~=" %%f in ('wmic process get Commandline 2^>NUL ^| find /I "cmd.exe" ^| find /I "launchGame.bat" ^| find /I /V "find" /C') do set /A "nbI=%%f" 35 | if %nbI% GEQ 1 ( 36 | echo ERROR^: launchGame^.bat is already^/still running^! If needed^, use ^'Wii-U Games^\BatchFw^\Kill BatchFw Processes^.lnk^'^. Aborting^! 37 | wmic process get Commandline 2>NUL | find /I "cmd.exe" | find /I "launchGame.bat" | find /I /V "find" 38 | pause 39 | exit 100 40 | ) 41 | 42 | REM : cd to BFW_TOOLS_PATH 43 | pushd !BFW_TOOLS_PATH! 44 | 45 | echo ========================================================= 46 | echo Wipe all traces on !USERDOMAIN! 47 | echo ========================================================= 48 | pause 49 | echo --------------------------------------------------------- 50 | echo Removing Cemu installs^.^.^. 51 | REM : delete all cemu installs on !USERDOMAIN! 52 | 53 | REM : search in logFile, getting only the last occurence 54 | set "previousPath=NONE" 55 | for /F "tokens=2 delims=~=" %%i in ('type !logFile! ^| find "install folder path" 2^>NUL') do ( 56 | set "previousPath="%%i"" 57 | if exist !previousPath! ( 58 | echo ^> remove !previousPath! 59 | rmdir /S /Q !previousPath! > NUL 2>&1 60 | REM : flush logFile 61 | call:cleanHostLogFile !previousPath! 62 | ) 63 | ) 64 | 65 | echo --------------------------------------------------------- 66 | echo Removing shortcuts created^.^.^. 67 | echo. 68 | 69 | REM : get the last location from logFile 70 | for /F "tokens=2 delims=~=" %%i in ('type !logFile! ^| find "Create shortcuts" 2^>NUL') do ( 71 | set "WIIU_GAMES_FOLDER="%%i"" 72 | if exist !WIIU_GAMES_FOLDER! ( 73 | 74 | rmdir /Q /S !WIIU_GAMES_FOLDER! > NUL 2>&1 75 | echo ^> !WIIU_GAMES_FOLDER! deleted ^! 76 | 77 | REM : flush logFile 78 | call:cleanHostLogFile !WIIU_GAMES_FOLDER! 79 | ) 80 | ) 81 | 82 | REM : search your current GLCache 83 | REM : check last path saved in log file 84 | 85 | REM : search in logFile, getting only the last occurence 86 | 87 | set "OPENGL_CACHE="NOT_FOUND"" 88 | for /F "tokens=2 delims=~=" %%i in ('type !logFile! ^| find /I "OPENGL_CACHE" 2^>NUL') do set "OPENGL_CACHE=%%i" 89 | 90 | if [!OPENGL_CACHE!] == ["NOT_FOUND"] goto:ending 91 | 92 | echo --------------------------------------------------------- 93 | echo BatchFw saves all your GPU Caches in !OPENGL_CACHE:"=! 94 | echo. 95 | choice /C yn /N /M "Do you want to also remove your GPU caches ? (y, n)" 96 | if !ERRORLEVEL! EQU 2 goto:ending 97 | 98 | set "GLCacheSavesFolder=!OPENGL_CACHE:GLCache=_BatchFW_CemuGLCache!\" 99 | 100 | if not exist !GLCacheSavesFolder! goto:cleanBfwVkCache 101 | rmdir /Q /S !GLCacheSavesFolder! > NUL 2>&1 102 | echo. 103 | echo ^> OpenGL caches were removed ^! 104 | 105 | :cleanBfwVkCache 106 | set "VkCacheSavesFolder=!OPENGL_CACHE:GLCache=_BatchFW_CemuVkCache!" 107 | 108 | if exist !VkCacheSavesFolder! ( 109 | rmdir /Q /S !VkCacheSavesFolder! > NUL 2>&1 110 | echo. 111 | echo ^> Vulkan caches were removed ^! 112 | ) 113 | REM : flush logFile 114 | call:cleanHostLogFile !OPENGL_CACHE! 115 | 116 | :ending 117 | echo ========================================================= 118 | echo done 119 | timeout /T 3 > NUL 2>&1 120 | 121 | endlocal 122 | exit /b 0 123 | 124 | goto:eof 125 | 126 | REM : ------------------------------------------------------------------ 127 | 128 | 129 | REM : ------------------------------------------------------------------ 130 | REM : functions 131 | 132 | :cleanHostLogFile 133 | REM : pattern to ignore in log file 134 | set "pat=%~1" 135 | set "logFileTmp="!logFile:"=!.bfw_tmp"" 136 | if exist !logFileTmp! ( 137 | del /F !logFile! > NUL 2>&1 138 | move /Y !logFileTmp! !logFile! > NUL 2>&1 139 | ) 140 | 141 | type !logFile! | find /I /V "!pat!" > !logFileTmp! 142 | 143 | del /F /S !logFile! > NUL 2>&1 144 | move /Y !logFileTmp! !logFile! > NUL 2>&1 145 | 146 | goto:eof 147 | REM : ------------------------------------------------------------------ 148 | 149 | REM : function to get and set char set code for current host 150 | :setCharSet 151 | 152 | REM : get charset code for current HOST 153 | set "CHARSET=NOT_FOUND" 154 | for /F "tokens=2 delims=~=" %%f in ('wmic os get codeset /value 2^>NUL ^| find "="') do set "CHARSET=%%f" 155 | 156 | if ["%CHARSET%"] == ["NOT_FOUND"] ( 157 | echo Host char codeSet not found in %0 ^? 158 | pause 159 | exit /b 9 160 | ) 161 | REM : set char code set, output to host log file 162 | 163 | chcp %CHARSET% > NUL 2>&1 164 | call:log2HostFile "charCodeSet=%CHARSET%" 165 | 166 | goto:eof 167 | REM : ------------------------------------------------------------------ 168 | 169 | :checkPathForDos 170 | 171 | set "toCheck=%1" 172 | 173 | REM : if implicit expansion failed (when calling this script) 174 | if ["!toCheck!"] == [""] ( 175 | echo Remove specials characters from %1 ^(such as ^&,^(,^),^!^)^, exiting 13 176 | exit /b 13 177 | ) 178 | 179 | REM : try to resolve 180 | if not exist !toCheck! ( 181 | echo This path ^(!toCheck!^) is not compatible with DOS^. Remove specials characters from this path ^(such as ^&,^(,^),^!^)^, exiting 11 182 | exit /b 11 183 | ) 184 | 185 | REM : try to list 186 | dir !toCheck! > NUL 2>&1 187 | if !ERRORLEVEL! NEQ 0 ( 188 | echo This path ^(!toCheck!^) is not compatible with DOS^. Remove specials characters from this path ^(such as ^&,^(,^),^!^)^, exiting 12 189 | exit /b 12 190 | ) 191 | 192 | exit /b 0 193 | goto:eof 194 | REM : ------------------------------------------------------------------ 195 | 196 | REM : function to log info for current host 197 | :log2HostFile 198 | REM : arg1 = msg 199 | set "msg=%~1" 200 | 201 | if not exist !logFile! ( 202 | set "logFolder="!BFW_PATH:"=!\logs"" 203 | if not exist !logFolder! mkdir !logFolder! > NUL 2>&1 204 | goto:logMsg2HostFile 205 | ) 206 | REM : check if the message is not already entierely present 207 | for /F %%i in ('type !logFile! ^| find /I "!msg!"') do goto:eof 208 | :logMsg2HostFile 209 | echo !msg!>> !logFile! 210 | 211 | goto:eof 212 | REM : ------------------------------------------------------------------ 213 | --------------------------------------------------------------------------------