Important information: this site is currently scheduled to go offline indefinitely by end of the year.

LEGO Pirates of the Caribbean

The Original Forum. Game archives, full of resources. How to open them? Get help here.
Rjack
n00b
Posts: 19
Joined: Thu Jun 14, 2012 9:53 am
Has thanked: 3 times
Been thanked: 3 times

Re: LEGO Pirates of the Caribbean

Post by Rjack »

aluigi wrote:Finally I have updated my ttgames.bms script for working correctly with all the games of the LEGO series included Lord of the Rings:

http://aluigi.org/papers/bms/ttgames.bms
Thanks, aluigi, the script works great.
I very want to translate the lego game(batman1,Indiana Jones1&2,etc.) to my language, although I am still working on the *.fnt(charmap).
But I couldn't test because I don't know how to reimport them.
Could you take a look when you have time, please?
User avatar
aluigi
VVIP member
VVIP member
Posts: 1916
Joined: Thu Dec 08, 2005 12:26 pm
Location: www.ZENHAX.com
Has thanked: 4 times
Been thanked: 664 times
Contact:

Re: LEGO Pirates of the Caribbean

Post by aluigi »

the script can't be used for reimporting the files because the file format uses chunks.
have you tried if the game can use the extracted files without the original archive?
Rjack
n00b
Posts: 19
Joined: Thu Jun 14, 2012 9:53 am
Has thanked: 3 times
Been thanked: 3 times

Re: LEGO Pirates of the Caribbean

Post by Rjack »

aluigi wrote:the script can't be used for reimporting the files because the file format uses chunks.
have you tried if the game can use the extracted files without the original archive?
I have tried, but it didn't work. :(
rip88
ultra-n00b
Posts: 2
Joined: Sun Oct 28, 2012 3:10 pm

Re: LEGO Pirates of the Caribbean

Post by rip88 »

Aluigi,
i make reimport to original file and the game work with CZECH fain. Text and font are on the GAME.DAT.
// 4 Edit the csv try Notepad+.

TY for very good work. BTW TTGame 0.6 script and new QuickBMS work. If you want i up the file on my dropbox.

Sorry for my very bad English.
namquang93
veteran
Posts: 115
Joined: Mon Apr 09, 2012 8:40 am
Has thanked: 50 times
Been thanked: 6 times

Re: LEGO Pirates of the Caribbean

Post by namquang93 »

RickyOs wrote:Try this one:

Code: Select all

# Traveller's Tales games DAT files extractor (script 0.5)
#  LEGO Harry Potter
#  LEGO Star Wars III
#  LEGO Pirates of the Caribbean
#
# this script is expansion to the original script from aluigi
# original script for QuickBMS http://aluigi.org/papers.htm#quickbms

comtype lz2k

get INFO_OFF long
if INFO_OFF & 0x80000000
    math INFO_OFF ^= 0xffffffff
    math INFO_OFF <<= 8
    math INFO_OFF += 0x100
endif
get INFO_SIZE long
log MEMORY_FILE INFO_OFF INFO_SIZE

get TYPE_BOH long MEMORY_FILE
get FILES long MEMORY_FILE
savepos INFO_OFF MEMORY_FILE

math TMP = FILES
math TMP *= 16  
math NAME_INFO = INFO_OFF
math NAME_INFO += TMP

goto NAME_INFO MEMORY_FILE
get NAMES long MEMORY_FILE
savepos NAME_INFO MEMORY_FILE

math TMP = NAMES
math TMP *= 8   
math NAME_OFF = NAME_INFO
math NAME_OFF += TMP

goto NAME_OFF MEMORY_FILE
get NAMECRC_OFF long MEMORY_FILE
savepos NAME_OFF MEMORY_FILE

math NAMECRC_OFF += NAME_OFF
goto NAMECRC_OFF MEMORY_FILE
for i = 0 < FILES
    get CRC long MEMORY_FILE
    putarray 0 i CRC
next i

if TYPE_BOH <= -2
    get DUMMY1 long MEMORY_FILE
    get DUMMY2 long MEMORY_FILE
    if DUMMY1 > 0
        print "Error: not implemented yet"
        cleanexit
    endif
endif

# print "files:       %FILES%"
# print "names:       %NAMES%"
# print "info_off:    %INFO_OFF%"
# print "info_size:   %INFO_SIZE%"
# print "name_info:   %NAME_INFO%"
# print "name_off:    %NAME_OFF%"
# print "namecrc_off: %NAMECRC_OFF%"

set NAMEZ long 0
set FULLNAME string ""
set FULLPATH string ""

for i = 0 < FILES
    do
        goto NAME_INFO MEMORY_FILE
        get NEXT short MEMORY_FILE
        get PREV short MEMORY_FILE
        get OFF long MEMORY_FILE
        savepos NAME_INFO MEMORY_FILE

        math OFF += NAME_OFF
        goto OFF MEMORY_FILE
        get NAME string MEMORY_FILE

        if NEXT & 0x8000    # 16bit sign conversion
            math NEXT |= 0xffff0000
        endif

        if PREV != 0
            getarray FULLPATH 1 PREV
        endif
        putarray 1 NAMEZ FULLPATH

        if NEXT > 0 # folder
            if NAME != ""
                string FULLPATH += NAME
                string FULLPATH += \
            endif
        else #file
        endif

        math NAMEZ += 1

    while NEXT > 0
    set FULLNAME string FULLPATH
    string FULLNAME += NAME

        math CRC = 0x811c9dc5
        strlen NAMESZ FULLNAME
        for j = 0 < NAMESZ
            getvarchr CHR FULLNAME j
            if CHR >= 0x61
                if CHR <= 0x7a
                    math CHR -= 0x20
                endif
            endif
            math CRC ^= CHR
            math CRC *= 0x199933
        next j
        for j = 0 < FILES
            getarray TMP 0 j
            if CRC == TMP
                break
            endif
        next j
        if j >= FILES
            print "Alert: the crc of the file %FULLNAME% has not been found, it can't be extracted!"
            #cleanexit
            # all wrongs!
            math j = i
            #math TMP = NEXT
            #math j = 0
            #math j -= NEXT
            #math j -= 1
        endif
        math TMP = j

        math TMP *= 16
        math TMP += INFO_OFF
        goto TMP MEMORY_FILE
        get OFFSET long MEMORY_FILE
        math OFFSET <<= 8
        get ZSIZE long MEMORY_FILE
        get SIZE long MEMORY_FILE
        get PACKED long MEMORY_FILE

        goto OFFSET
        getdstring SIGN 4
        if SIGN == "LZ2K"
            set PACKED long 2
        else
            set PACKED long 0
        endif

        if PACKED & 2
            callfunction UNLZ2K
            log FULLNAME 0 SIZE MEMORY_FILE2
        else
            if SIZE != 0
            if ZSIZE != 0
            if SIZE != ZSIZE
                print "SIZE (%SIZE%) and ZSIZE (%ZSIZE%) differ, contact me"
                cleanexit
            endif
            endif
            endif
            log FULLNAME OFFSET SIZE
        endif
next i

startfunction UNLZ2K
    putvarchr MEMORY_FILE2 SIZE 0
    log MEMORY_FILE2 0 0
    append
    for TMPSZ = 0 < ZSIZE
        goto OFFSET
        getdstring SIGN 4
        if SIGN != "LZ2K"
            print "Error: the signature at offset %OFFSET% (%SIGN%) is not LZ2K, contact me"
            cleanexit
        endif
        get LZ2K_SIZE long
        get LZ2K_ZSIZE long
        savepos OFFSET
        if LZ2K_ZSIZE == LZ2K_SIZE
            log MEMORY_FILE2 OFFSET LZ2K_SIZE
        else
            clog MEMORY_FILE2 OFFSET LZ2K_ZSIZE LZ2K_SIZE
        endif
        math OFFSET += LZ2K_ZSIZE
        savepos TMP MEMORY_FILE2
        math TMPSZ += 12
        math TMPSZ += LZ2K_ZSIZE
    next
    append
endfunction
I used Traveller's Tales games DAT files extractor (script 0.5), Export and ReImport works Perfectly with .DAT on PC, but with PS3 version, i have some problem:
Image
Image
Thanks for any help!
User avatar
aluigi
VVIP member
VVIP member
Posts: 1916
Joined: Thu Dec 08, 2005 12:26 pm
Location: www.ZENHAX.com
Has thanked: 4 times
Been thanked: 664 times
Contact:

Re: LEGO Pirates of the Caribbean

Post by aluigi »

Those of the PS3 don't work because they use something on the last chunk of each file.
But you can modify the script to skip the compressed files and so extracting all the others (mainly audio, video and music)

If you check the latest version of ttgames.bms I wrote this information in the notes at the beginning:

Code: Select all

# Note that the script may not work with the compressed files of
# Lego Movie for PS3, in case of crashes or other issues you can
# extract only the non compressed files by setting
# EXTRACT_COMPRESSED to 0.
namquang93
veteran
Posts: 115
Joined: Mon Apr 09, 2012 8:40 am
Has thanked: 50 times
Been thanked: 6 times

Re: LEGO Pirates of the Caribbean

Post by namquang93 »

aluigi wrote:Those of the PS3 don't work because they use something on the last chunk of each file.
But you can modify the script to skip the compressed files and so extracting all the others (mainly audio, video and music)

If you check the latest version of ttgames.bms I wrote this information in the notes at the beginning:

Code: Select all

# Note that the script may not work with the compressed files of
# Lego Movie for PS3, in case of crashes or other issues you can
# extract only the non compressed files by setting
# EXTRACT_COMPRESSED to 0.
Thanks! But I'm not coder. Thank you very much again,
if EXTRACT_COMPRESSED != 0
I will changed: if
EXTRACT_COMPRESSED = 0
?
Thanks!
anahuj
ultra-n00b
Posts: 4
Joined: Wed Dec 21, 2011 4:48 pm
Been thanked: 1 time

Re: LEGO Pirates of the Caribbean

Post by anahuj »

aluigi wrote:the script can't be used for reimporting the files because the file format uses chunks.
have you tried if the game can use the extracted files without the original archive?
Can you explain this?
Is this something that we need better quickbms?
Post Reply