Thank you for creating this useful script!
I hope the original author doesn't mind, but I took the liberty of updating the version (1.6.5) and adding some features that I will use.
1. The code page of this script has been changed to UTF-8 (65001).
2. Two parameters, extractPause and cleanup, have been added.
2.1 extractPause
y: Extract will automatically check if the titlekey file exists, display a prompt message and wait for user confirmation,
n: Extract directly without waiting for user confirmation.
2.2 cleanup
y: remove all temporary files,
n: don't delete anything
3. The Setting option has been added, which allows modifying the values of extractPause and cleanup parameters during runtime.
4. The LayeredFS (romfs.bin, exefs) option has been added.
4.1 Extract Romfs to Files
4.2 List files in RomFS
4.3 Uncompressed Nintendo Shared Object (nso0)
4.4 Npdm to JSON
5. Update hactool to the latest version 1.4.0.
Regarding the warning "Key () must be 32 hex digits!", I roughly understand the reason.
In my situation,
When doing 2+2 (【2.eShop NSP】+【2.NSP to LayeredFS】) or
2+4 (【2.eShop NSP】+【4.Extract GAME Files】),
the *.tik file is not generated in the "Extracted_NSP" directory.
As a result, the titlekey in the script will be empty, and hactool will display the warning "Key () must be 32 hex digits!".
To solve this issue, first try to obtain the *.tik file as much as possible, such as from the update.nsp of the same game.
Then, manually execute hactool.