ROM Hack Help needed to unpack and pack a script file.

TyRaNtM

I did some projects..
OP
Member
Joined
Oct 13, 2007
Messages
1,008
Trophies
1
Age
37
Location
Chile
Website
www.power-ups.net
XP
596
Country
Cote d'Ivoire
I need help unpacking and packing a script file in Inazuma Eleven EUR English.
The files are compressed, and are really weird if you see that files in a hex editor.
The files are LZ77, i suppose.

If you are a coder or at least have a experience with rom hacking, will be good if you can support us, because is nearly the only thing left to finish our project.

The files are in:
script/en/evet.pkb
script/en/evet.pkh
script/en/mchat.pkb
script/en/mchat.pkh


Or you can PM if you want the files alone.
 

rastsan

8 baller, Death Wizard,
Member
Joined
May 28, 2008
Messages
1,002
Trophies
1
Location
toronto
Website
rastsan.wordpress.com
XP
413
Country
Canada
quickbms might work for you on this you just have to be patient in writing the script file... partial one for xenoblade (same file name but not the same output - what you need to change).

QUOTE said:
# Game: Xenoblade (Wii)
# by Falo - 2010
# script for QuickBMS http://aluigi.org/papers.htm#quickbms
#
# usage :
#
# use WiiScrubber to extract all *.pkb files
# use any u8 tool (arc extractor) to extract static.arc
# you should then have *.pkb and *.pkh files
# use this script on *.pkb

endian big

Open FDDE PKH 1

get Temp long 1 # always 0x00FE1200
get Temp long 1
get ofsHashTable long 1 # not sure, HashTable or FileIDTable
get FileSize long 1
get numFiles long 1

set ofsSizeTable numFiles
set ofsOffsetTable numFiles

math ofsSizeTable *= 8
math ofsOffsetTable *= 2

math ofsSizeTable += ofsHashTable
math ofsOffsetTable += ofsSizeTable

for i = 0 < numFiles
goto ofsHashTable 1
get Hash long 1 # not sure, Hash or FileID
get Temp long 1 # always 0x0
goto ofsSizeTable 1
get Size short 1
goto ofsOffsetTable 1
get Offset long 1

math Size *= 2048
math Offset *= 2048

# use hash/fileid as filename
set Name Hash
set FileExt ".dat"

# get FileExt
goto Offset
get FileID long

if FileID = 1437218861 # Nintendo ARC (U8)
set FileExt ".arc"
endif
if FileID = 1651664243 # Nintendo BRRES
set FileExt ".brres"
endif
if FileID = 2142000 # Nintendo TPL
set FileExt ".tpl"
endif
if FileID = 1264144384 # Xenoblade KYP -> BRRES Archive
set FileExt ".kyp"
endif
if FileID = 1835229440 # Xenoblade MCA
set FileExt ".mca"
endif
if FileID = 1145131057 # Xenoblade DAP1
set FileExt ".dap"
endif
if FileID = 1280263241 # Xenoblade LODI
set FileExt ".lod"
endif

string Name += FileExt

log Name Offset Size

# next file, increase all offsets
math ofsHashTable += 8
math ofsSizeTable += 2
math ofsOffsetTable += 4
next i

CleanExit

Look up the faq for writing quickbms you will understand. I will be using the same type thing for unpacking some files for duel love. Just re-read fast6191's notes and use the saved table of offsets and filesize(s) from crystaltile2. it will be alot of work but it will be decompressed... recompressed I don't know how to do...

you will need to edit the fileid parts for sure. alot of other things too but you will have it decompressed.
 

Site & Scene News

Popular threads in this forum

General chit-chat
Help Users
  • No one is chatting at the moment.
  • S @ salazarcosplay:
    the author has the final aproval
  • S @ salazarcosplay:
    hunter x hunter
  • S @ salazarcosplay:
    he has not allowed anyone to continue it for him for example
  • Xdqwerty @ Xdqwerty:
    @salazarcosplay, theres a dragon ball af mod for budokai 3
  • Xdqwerty @ Xdqwerty:
    updated ship of harkinian, gonna install some hd texture pack
  • Xdqwerty @ Xdqwerty:
    I might download rayman revolution for my ps3
  • BigOnYa @ BigOnYa:
    I may try the new ram site, and download more RAM to my Switch. Not sure if ddr3 is the right ram
    for it tho. Edit- no it uses floppy Ram, just like @AncientBoi
    +1
  • Xdqwerty @ Xdqwerty:
    aeiou
  • BigOnYa @ BigOnYa:
    And sometimes Z
  • SylverReZ @ SylverReZ:
    @K3Nv2, MAGA supporters be wearing tin foil hats lol.
    +1
  • Xdqwerty @ Xdqwerty:
    @SylverReZ, whats maga?
  • BigOnYa @ BigOnYa:
    It stands for Maniacs Against General Acceptance
  • Xdqwerty @ Xdqwerty:
    @BigOnYa, people rejecting general consensus about stuff?
    +1
  • BigOnYa @ BigOnYa:
    Yup, nuh its really just Trump followers
  • Xdqwerty @ Xdqwerty:
    @BigOnYa, im not american so i dont care about trump
    +1
  • Xdqwerty @ Xdqwerty:
    or us elections
  • BigOnYa @ BigOnYa:
    Me niether, us north Koreans don't care
  • Xdqwerty @ Xdqwerty:
    good night
  • BakerMan @ BakerMan:
    i don't care either, even if i'm american
  • BakerMan @ BakerMan:
    truth be told, i agree with psi, i dislike both candidates, but i'd probably vote trump simply because the economy was better during his presidency
  • AngryCinnabon @ AngryCinnabon:
    Just be careful, if trump ends up winning and using project 2025 America might really change...for the worse.
  • AngryCinnabon @ AngryCinnabon:
    I'm not american and even that sends shivers down my spine.
  • AngryCinnabon @ AngryCinnabon:
    anything that offers trump an opportunity to become an actual dictator
    is bad in my book, i could care less if it wasn't for that...
  • K3Nv2 @ K3Nv2:
    Canada: America's Russia
    K3Nv2 @ K3Nv2: Canada: America's Russia