02-26-2016, 08:10 PM
(This post was last modified: 02-26-2016, 08:29 PM by Struggleton!.)
Code:
# For use with QuickBMS, by aluigi of zenhax: http://aluigi.altervista.org/quickbms.htm
# Written by ThatTrueStruggle
# Most of the info in this script can be found here: http://www.gtamodding.com,
# and from using Steve-M's Renderware Analyze
# Generic Renderware Header
get CHUNKID long
get SECTIONSZ long
get VERSION long
# Generic Renderware Header
goto 0x18
get TXCOUNT short # Get texture count
get CONSOLEDESCRIPTOR short # Get console id
for i = 0 < TXCOUNT
# Get the header again
get CHUNKID long
get SECTIONSZ long
get VERSION long
# Generic Renderware Header
savepos OFFSET # Save our position for later
getdstring DUMMY 0x23 # Skip header info
get NAME string # Get File Name
log NAME OFFSET SECTIONSZ # Save to File using info gained earlier
goto OFFSET # Go back to he saved offset
goto SECTIONSZ 0 SEEK_CUR # Go to the next file, repeat
next i
This should work on the TXD archives. However it extracts extra header info that may interfere with Puggsoy's script working. Not sure. I gave explanations in the script itself. Also I can say that the stuff extracted from the file are not TM2 files; The files after the first one are just palettes I think :/