Page 1 of 1
WRC Generations .PKG bms
Posted: Sat Nov 05, 2022 7:09 pm
by Franco
Hello, the existing WRC 10 script does not work.
Can you please make a bms script for this game.
A sample file is below.
https://www.mediafire.com/file/lwqgp029 ... 2.PKG/file
Re: WRC Generations .PKG bms
Posted: Mon Nov 14, 2022 9:34 pm
by Mr.Mouse
The file information is XORed with the following key:
Re: WRC Generations .PKG bms
Posted: Tue Nov 15, 2022 7:17 pm
by Franco
Mr.Mouse wrote: ↑Mon Nov 14, 2022 9:34 pm
The file information is XORed with the following key:
Thank you very much. But how do I use this key?
So can you please create a script to open the file.
Re: WRC Generations .PKG bms
Posted: Tue Nov 22, 2022 6:07 pm
by Franco
Can someone please take a look?
Re: WRC Generations .PKG bms
Posted: Tue Nov 22, 2022 10:29 pm
by Ekey
Some fields are now 64-bit
Code: Select all
# WRC 7 / WRC 10 FIA World Rally Championship (script 0.2.2)
# WRC Generations
# script for QuickBMS http://quickbms.aluigi.org
comtype lz4f # "\x04\x22\x4d\x18" magic is lz4f
set KEY string ""
getdstring SIGN 4
goto 0
if SIGN u!= "PPKG"
# the key is "35DsFsyDFFUC4NVANPpYggyakreWkJfy" (quickbms gives problems using the key as-is...)
set KEY string "0x33 0x35 0x44 0x73 0x46 0x73 0x79 0x44 0x46 0x46 0x55 0x43 0x34 0x4E 0x56 0x41 0x4E 0x50 0x70 0x59 0x67 0x67 0x79 0x61 0x6B 0x72 0x65 0x57 0x6B 0x4A 0x66 0x79"
filexor KEY
getdstring DUMMY 0x180 # unknown data
endif
idstring "PPKG"
get VER long # 2 or 4 (WRC Generations)
get FILES long
get INFO_SIZE long
getdstring ZERO 0x20
for i = 0 < FILES
filexor KEY 0
get NAMESZ long
getdstring NAME NAMESZ
get NAME_CRC long
get OFFSET longlong
get TSTAMP longlong
get ZSIZE longlong # PKGB + ZSIZE + PKGE
get SIZE longlong # PKGB + SIZE + PKGE
get ZIP long
if VER == 2
get ZCRC long
get CRC long
elif VER == 4
get ZCRC longlong
get CRC longlong
else
print "Error: unsupported version -> %VER% contact me"
cleanexit
endif
getdstring ZERO 0x20
filexor ""
math OFFSET + 4 # PKGB
if ZIP == 0
log NAME OFFSET SIZE
else
clog NAME OFFSET ZSIZE SIZE
endif
next i
Re: WRC Generations .PKG bms
Posted: Wed Nov 23, 2022 4:40 pm
by Franco
Ekey wrote: ↑Tue Nov 22, 2022 10:29 pm
Some fields are now 64-bit
Code: Select all
# WRC 7 / WRC 10 FIA World Rally Championship (script 0.2.2)
# WRC Generations
# script for QuickBMS http://quickbms.aluigi.org
comtype lz4f # "\x04\x22\x4d\x18" magic is lz4f
set KEY string ""
getdstring SIGN 4
goto 0
if SIGN u!= "PPKG"
# the key is "35DsFsyDFFUC4NVANPpYggyakreWkJfy" (quickbms gives problems using the key as-is...)
set KEY string "0x33 0x35 0x44 0x73 0x46 0x73 0x79 0x44 0x46 0x46 0x55 0x43 0x34 0x4E 0x56 0x41 0x4E 0x50 0x70 0x59 0x67 0x67 0x79 0x61 0x6B 0x72 0x65 0x57 0x6B 0x4A 0x66 0x79"
filexor KEY
getdstring DUMMY 0x180 # unknown data
endif
idstring "PPKG"
get VER long # 2 or 4 (WRC Generations)
get FILES long
get INFO_SIZE long
getdstring ZERO 0x20
for i = 0 < FILES
filexor KEY 0
get NAMESZ long
getdstring NAME NAMESZ
get NAME_CRC long
get OFFSET longlong
get TSTAMP longlong
get ZSIZE longlong # PKGB + ZSIZE + PKGE
get SIZE longlong # PKGB + SIZE + PKGE
get ZIP long
if VER == 2
get ZCRC long
get CRC long
elif VER == 4
get ZCRC longlong
get CRC longlong
else
print "Error: unsupported version -> %VER% contact me"
cleanexit
endif
getdstring ZERO 0x20
filexor ""
math OFFSET + 4 # PKGB
if ZIP == 0
log NAME OFFSET SIZE
else
clog NAME OFFSET ZSIZE SIZE
endif
next i
Ekey thank you very much. You're the king man, thanks
