Initial commit
This commit is contained in:
parent
92895de2e6
commit
4c32d7f798
9 changed files with 72 additions and 0 deletions
6
.gitignore
vendored
6
.gitignore
vendored
|
@ -1,3 +1,9 @@
|
||||||
|
# Custom ignore files
|
||||||
|
*.app
|
||||||
|
*.cia
|
||||||
|
*.zip
|
||||||
|
*.7z
|
||||||
|
|
||||||
# Windows image file caches
|
# Windows image file caches
|
||||||
Thumbs.db
|
Thumbs.db
|
||||||
ehthumbs.db
|
ehthumbs.db
|
||||||
|
|
3
go.bat
Normal file
3
go.bat
Normal file
|
@ -0,0 +1,3 @@
|
||||||
|
@echo off
|
||||||
|
for %%x in (input\*.cia) do call tools\process.bat %%x input\hs.app
|
||||||
|
pause
|
0
input/dummy.txt
Normal file
0
input/dummy.txt
Normal file
13
readme.md
Normal file
13
readme.md
Normal file
|
@ -0,0 +1,13 @@
|
||||||
|
**Universal Inject Generator**
|
||||||
|
|
||||||
|
|
||||||
|
This script will generate an inject-ready app to inject over the Health & Safety app in the 3DS console. The package includes code by @Syphurith, CTRtool (by profi200) and 3DStool (by dnasdw).
|
||||||
|
|
||||||
|
This is how it works:
|
||||||
|
* This is used in conjunction with most recent (mine) Decrypt9's "Dump Health&Safety" and "Inject Health&Safety" features
|
||||||
|
* Put hs.app (dumped via Decrypt9) plus as many homebrew CIAs as you like into the input folder
|
||||||
|
* Run go.bat, you'll get one inject-ready .app per CIA
|
||||||
|
* If the last one for some reason doesn't work, you may try deep-decrypting (via Decrypt9) your CIAs first.
|
||||||
|
* To inject, rename inject-ready .app to hs.app, put it into the root of your 3DS SD card and inject via Decrypt9
|
||||||
|
|
||||||
|
You should always generate your inject-ready .apps yourself and never take ones from other persons. There might be a version mismatch in the H&S app, leading to it not working otherwise.
|
BIN
tools/3dstool.exe
Normal file
BIN
tools/3dstool.exe
Normal file
Binary file not shown.
BIN
tools/MergeExHeader.exe
Normal file
BIN
tools/MergeExHeader.exe
Normal file
Binary file not shown.
BIN
tools/ctrtool.exe
Normal file
BIN
tools/ctrtool.exe
Normal file
Binary file not shown.
1
tools/ignore_3dstool.txt
Normal file
1
tools/ignore_3dstool.txt
Normal file
|
@ -0,0 +1 @@
|
||||||
|
// regex: ECMAScript grammar and case insensitive
|
49
tools/process.bat
Normal file
49
tools/process.bat
Normal file
|
@ -0,0 +1,49 @@
|
||||||
|
@echo off
|
||||||
|
|
||||||
|
echo [!] --- UNIVERSAL INJECT GENERATOR V0.3 ---
|
||||||
|
echo .
|
||||||
|
echo .
|
||||||
|
|
||||||
|
echo.
|
||||||
|
echo [+] IDENTIFY FILES TO WORK WITH
|
||||||
|
ren work work_old
|
||||||
|
del /s /q work_old
|
||||||
|
rd /s /q work_old
|
||||||
|
del /q hs.*
|
||||||
|
md work
|
||||||
|
copy /y /v %2 work\hs.app
|
||||||
|
tools\ctrtool -x --contents work\ciacnt %1
|
||||||
|
ren "work\ciacnt.0000.*" inject.app
|
||||||
|
|
||||||
|
echo.
|
||||||
|
echo [+] EXTRACT HS AND INJECT APP
|
||||||
|
tools\3dstool -x -f work\hs.app --header work\hs_hdr.bin --exh work\hs_exhdr.bin --plain work\hs_plain.bin --logo work\hs_logo.bin --exefs work\hs_exefs.bin --romfs work\hs_romfs.bin
|
||||||
|
tools\3dstool -x -f work\inject.app --exh work\inject_exhdr.bin --exefs work\inject_exefs.bin
|
||||||
|
tools\3dstool -x -f work\hs_exefs.bin --exefs-dir work\hs_exefs
|
||||||
|
tools\3dstool -x -f work\inject_exefs.bin --exefs-dir work\inject_exefs
|
||||||
|
|
||||||
|
echo.
|
||||||
|
echo [+] GENERATE NEW EXEFS
|
||||||
|
copy /y /v work\inject_exefs\code.bin work\hs_exefs\code.bin
|
||||||
|
rem copy /y /v work\inject_exefs\banner.bnr work\hs_exefs\banner.bnr
|
||||||
|
rem copy /y /v work\inject_exefs\icon.icn work\hs_exefs\icon.icn
|
||||||
|
tools\3dstool -c -z -t exefs -f work\hs_mod_exefs.bin --exefs-dir work\hs_exefs --header work\hs_exefs.bin
|
||||||
|
|
||||||
|
echo.
|
||||||
|
echo [+] GENERATE NEW ROMFS
|
||||||
|
md work\dummy_romfs
|
||||||
|
fsutil file createnew work\dummy_romfs\dummy.bin 16
|
||||||
|
tools\3dstool -c -t romfs -f work\dummy_romfs.bin --romfs-dir work\dummy_romfs
|
||||||
|
|
||||||
|
echo.
|
||||||
|
echo [+] MERGE EXHEADER
|
||||||
|
tools\MergeExHeader work\inject_exhdr.bin work\hs_exhdr.bin work\merge_exhdr.bin
|
||||||
|
|
||||||
|
echo.
|
||||||
|
echo [+] REBUILD HS INJECT APP
|
||||||
|
if exist work\hs_logo.bin (tools\3dstool -c -t cxi -f %~n1.app --header work\hs_hdr.bin --exh work\merge_exhdr.bin --plain work\hs_plain.bin --logo work\hs_logo.bin --exefs work\hs_mod_exefs.bin --romfs work\dummy_romfs.bin) else (tools\3dstool -c -t cxi -f %~n1.app --header work\hs_hdr.bin --exh work\merge_exhdr.bin --plain work\hs_plain.bin --exefs work\hs_mod_exefs.bin --romfs work\dummy_romfs.bin)
|
||||||
|
for %%i in (work\hs.app) do set HS_ORIGINAL_SIZE=%%~zi
|
||||||
|
for %%i in (%~n1.app) do set HS_INJECT_SIZE=%%~zi
|
||||||
|
echo [*] HS APP ORIGINAL SIZE: %HS_ORIGINAL_SIZE% byte
|
||||||
|
echo [*] HS APP INJECT SIZE : %HS_INJECT_SIZE% byte
|
||||||
|
if HS_ORIGINAL_SIZE LSS HS_INJECT_SIZE (echo [!] INJECT APP IS BIGGER THAN HS APP) else (echo [+] SIZE IS OKAY!)
|
Loading…
Reference in a new issue