Luigi Auriemma

aluigi.org (ARCHIVE-ONLY FORUM!)
It is currently 19 Jul 2012 16:11

All times are UTC [ DST ]





Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 9 posts ] 
Author Message
 Post subject: battlefield bad company 2 sounds
PostPosted: 23 Jun 2010 15:28 

Joined: 23 Jun 2010 15:25
Posts: 4
Hey,
I remember a while back a script was posted on the zentax forums to extract the huge 641mb stream_sounds.fbrb file.
But the problem is i only have 1.87gb of ram so it gives me a dump_memory error file doesn't exist.
And since someone was having the same problem a script seemedto have been posted to extract it not using the ram
but this scritp was removed. Can somebody resend it please?
Thanks.


Top
 Profile  
 
 
 Post subject: Re: battlefield bad company 2 sounds
PostPosted: 24 Jun 2010 10:51 

Joined: 24 Jun 2010 10:04
Posts: 70
Location: aluigi not @ home
I guess you mean the following valid only for non-compressed archives
http://aluigi.org/papers/bms/fbrb_nogzip.bms

otherwise is necessary to modify the original script


Top
 Profile  
 
 Post subject: Re: battlefield bad company 2 sounds
PostPosted: 25 Jun 2010 09:20 

Joined: 23 Jun 2010 15:25
Posts: 4
No that is not what I ment, I mean a script that was posted a while back it was the same as the roiginal but it wouldn't extract to memory.
I've tried nogzip already, the streaming soudns file is compressed it is 641mb.


Top
 Profile  
 
 Post subject: Re: battlefield bad company 2 sounds
PostPosted: 25 Jun 2010 12:15 

Joined: 24 Jun 2010 10:04
Posts: 70
Location: aluigi not @ home
but isn't enough to make the swap file of Windows bigger?
set it to at least 2gb and it should work perfectly.

for a possible update of the script you need to wait that I return at home but if you want you can try the following one that I have made on the fly and I have NOT tested:
Code:
# Battlefield: Bad Company (script 0.1.3) (low RAM version)
# script for QuickBMS http://aluigi.org/papers.htm#quickbms

endian big
comtype deflate
idstring "FbRB"
get SIZE long
savepos OFFSET
set MEM_FILE long 1
callfunction gzip_fbrb_sux

math OFFSET += SIZE
get SIZE asize
math SIZE -= OFFSET
goto OFFSET
set MEM_FILE long 2
callfunction gzip_fbrb_sux

get VER long MEMORY_FILE
get INFO_OFF long MEMORY_FILE
savepos NAME_BASE MEMORY_FILE
math INFO_OFF += NAME_BASE
goto INFO_OFF MEMORY_FILE
get FILES long MEMORY_FILE
for i = 0 < FILES
    get NAMEOFF long MEMORY_FILE
    get DUMMY long MEMORY_FILE
    get OFFSET long MEMORY_FILE
    get SIZE long MEMORY_FILE
    get XSIZE long MEMORY_FILE
    get NAMESZ long MEMORY_FILE

    savepos TMP MEMORY_FILE
    math NAMEOFF += NAME_BASE
    goto NAMEOFF MEMORY_FILE
    #getdstring NAME NAMESZ MEMORY_FILE
    get NAME string MEMORY_FILE
    goto TMP MEMORY_FILE

    open "." TEMPORARY_FILE 1
    log NAME OFFSET SIZE 1
next i

# fbrb sux, it specifies a wrong size for the gzip file in some archives (like ondemand_awards-00.fbrb)
# so when QuickBMS goes at its end to find the uncompressed size field it finds a zero... bad
startfunction gzip_fbrb_sux
    savepos TMP_OFF
    endian little
    get GZIP_SIGN short
    if GZIP_SIGN == 0x8b1f
        get CM byte
        get FLAGS byte
        get MTIME long
        get XFL byte
        get OS byte
        if FLAGS & 4
            get TMP short
            getdstring TMP TMP
        endif
        if FLAGS & 8
            get TMP string
        endif
        if FLAGS & 16
            get TMP string
        endif
        if FLAGS & 2
            get TMP short
        endif
        savepos TMP
        math SIZE += OFFSET
        math SIZE -= 4  # uncompressed size
        goto SIZE
        get XSIZE long
        math SIZE -= TMP
        if XSIZE < SIZE # so also if it's 0
            math XSIZE = SIZE
            math XSIZE *= 12    # enough?
        endif
        if MEM_FILE == 1
            clog MEMORY_FILE TMP SIZE XSIZE
        else
            clog TEMPORARY_FILE TMP SIZE XSIZE
        endif
    else
        if MEM_FILE == 1
            log MEMORY_FILE OFFSET SIZE
        else
            log TEMPORARY_FILE OFFSET SIZE
        endif
    endif
    goto TMP_OFF
    endian big
endfunction


Top
 Profile  
 
 Post subject: Re: battlefield bad company 2 sounds
PostPosted: 25 Jun 2010 12:31 

Joined: 23 Jun 2010 15:25
Posts: 4
Got the following error...
Error: MEMORY_FILE has not been used in this script yet


Top
 Profile  
 
 Post subject: Re: battlefield bad company 2 sounds
PostPosted: 26 Jun 2010 22:48 

Joined: 13 Aug 2007 21:44
Posts: 4068
Location: http://aluigi.org
here that modified script works perfectly so I guess you have an old version of QuickBMS, update it:
http://aluigi.org/papers.htm#quickbms


Top
 Profile  
 
 Post subject: Re: battlefield bad company 2 sounds
PostPosted: 10 Jan 2011 02:44 

Joined: 09 Jan 2011 23:34
Posts: 4
Am I doing anything wrong or won't the type of converting from .res to .wav of bad company works?
I do the same steps for Bad Company 2. With your programm, Luigi (by the way thanks for this) I created the res files, but than the ea_multi_xma.exe didn't work. Everytime the ea_multi_xma.exe don't realized my res files as a res file. So that's my mistake or did EA change anything?

rgds

Gwanw


Top
 Profile  
 
 Post subject: Re: battlefield bad company 2 sounds
PostPosted: 10 Jan 2011 10:11 

Joined: 13 Aug 2007 21:44
Posts: 4068
Location: http://aluigi.org
maybe ask to hcs, he knows for sure more than me about these files and about his tool


Top
 Profile  
 
 Post subject: Re: battlefield bad company 2 sounds
PostPosted: 10 Jan 2011 10:25 

Joined: 09 Jan 2011 23:34
Posts: 4
Ok, thanks, I sended him a PM :).


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 9 posts ] 

All times are UTC [ DST ]


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for: