I've been trying to extract files from a Switch game called Taisho x Alice and although the game files are .PAK, none of the various PAK tools or 7zip I've tried are able to extract these files.
Here's an example of one of the PAK archives:
https://www.mediafire.com/file/1fa0obmt ... G.PAK/file
Switch PAK archive
-
- Posts: 179
- Joined: Tue Jan 18, 2022 12:21 am
Re: Switch PAK archive
Riesz wrote:I've been trying to extract files from a Switch game called Taisho x Alice and although the game files are .PAK, none of the various PAK tools or 7zip I've tried are able to extract these files.
Here's an example of one of the PAK archives:
https://www.mediafire.com/file/1fa0obmt ... G.PAK/file
This will extract the pak.
i dont know if it will work with all files.
if not, send more samples.
Code: Select all
get NOIDEA long
get ENTRIES long
getdstring NOIDEA 0x24
for RIP = 1 to ENTRIES
get OFFSET long
xmath OFFSET "(OFFSET * 0X800)"
get SIZE long
log "" OFFSET SIZE
next RIP
-
- Posts: 9
- Joined: Mon Nov 15, 2021 8:56 pm
Re: Switch PAK archive
Here are a few more example files
https://www.mediafire.com/file/lkx1ktv6 ... s.zip/file
https://www.mediafire.com/file/lkx1ktv6 ... s.zip/file
-
- Posts: 179
- Joined: Tue Jan 18, 2022 12:21 am
Re: Switch PAK archive
Here
Ugly but works.
Code: Select all
# Script by Rabatini (Luke)
# Taisho x Alice - SWITCH (.PAK)
# Version 0.1b
get NOIDEA long
get ENTRIES long
get NOIDEA long
get matematica long
getdstring zeros 0x10
get check long
if check == 0x00000200
get name_table long
savepos pointer_table
goto name_table
get name string
savepos name_table
goto pointer_table
for RIP = 1 to ENTRIES
get OFFSET long
xmath OFFSET "(OFFSET * matematica)"
get SIZE long
savepos table
log name OFFSET SIZE
goto name_table
get name string
savepos name_table
goto table
next RIP
else
goto 0x08
getdstring NOIDEA 0x20
get check long
if check == 0
for RIP = 1 to ENTRIES
get OFFSET long
xmath OFFSET "(OFFSET * MATEMATICA)"
get SIZE long
log "" OFFSET SIZE
next rip
elif check > 0
get zeros longlong
for RIP = 1 to ENTRIES
get OFFSET long
xmath OFFSET "(OFFSET * MATEMATICA)"
get SIZE long
log "" OFFSET SIZE
next RIP
endif
Ugly but works.