Skip to content
This repository has been archived by the owner on Jan 12, 2022. It is now read-only.

Commit

Permalink
Fix variable in update.bat, clear romfs prior to building in make.bat
Browse files Browse the repository at this point in the history
  • Loading branch information
Ryuzaki-MrL committed Jun 11, 2016
1 parent a19d47f commit 29a2bed
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
1 change: 1 addition & 0 deletions make.bat
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ if not exist "input\%title%\*.smc" if not exist "input\%title%\*.sfc" (
set /p author=Publisher:
set /p serial=Product Code:
set /p id=Unique Id:
del /f /q romfs
if exist "input\%title%\*.smc" (
copy /b "input\%title%\*.smc" romfs\rom.smc
) else (
Expand Down
9 changes: 4 additions & 5 deletions update.bat
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,8 @@ for /f "delims=" %%i in ('dir /b /s "*.cia"') do (
set /p "id="
set /p "serial="
)

del info.txt

tools\ctrtool -x -t cia --contents ncch "%%i"
for /f "delims=" %%j in ('dir /b /s "ncch*.*"') do (
tools\ctrtool -x -t ncch --exefsdir exefs --romfsdir romfs "%%j"
Expand All @@ -18,7 +19,7 @@ for /f "delims=" %%i in ('dir /b /s "*.cia"') do (
<romfs\rom.txt set /p title=

set /p choice="Do you want to include or update any extra files for !title!? (Y/N): " %=%
if [%choice%]==[Y] (
if [!choice!]==[Y] (
if exist "input\!title!\*.bmp" copy /b "input\!title!\*.bmp" romfs\blargSnesBorder.bmp
if exist "input\!title!\*.ini" copy /b "input\!title!\*.ini" romfs\blargSnes.ini
if exist "input\!title!\*.smc" (
Expand All @@ -27,7 +28,7 @@ for /f "delims=" %%i in ('dir /b /s "*.cia"') do (
copy /b "input\!title!\*.sfc" romfs\rom.smc
)
)
if [%choice%]==[y] (
if [!choice!]==[y] (
if exist "input\!title!\*.bmp" copy /b "input\!title!\*.bmp" romfs\blargSnesBorder.bmp
if exist "input\!title!\*.ini" copy /b "input\!title!\*.ini" romfs\blargSnes.ini
if exist "input\!title!\*.smc" (
Expand All @@ -37,11 +38,9 @@ for /f "delims=" %%i in ('dir /b /s "*.cia"') do (
)
)

:make
tools\makerom -f cia -target t -rsf "tools\custom.rsf" -o "%%i" -exefslogo -icon "exefs\icon.bin" -banner "exefs\banner.bin" -elf "tools\blargSnes.elf" -DAPP_TITLE="!title!" -DAPP_PRODUCT_CODE="!serial!" -DAPP_UNIQUE_ID=0x!id! -DAPP_ROMFS="romfs"
rmdir /s /q exefs
del /f /q romfs
del info.txt
echo Done
)
echo All CIAs were updated

0 comments on commit 29a2bed

Please sign in to comment.