Extracting munged from LVL files?
Moderator: Moderators
- giftheck
- Droid Pilot Assassin

- Posts: 2218
- Joined: Mon Jan 19, 2009 5:58 pm
- Projects :: Star Wars Battlefront Anniversary
Extracting munged from LVL files?
Is there a way to extract munged files from the LVL files? I want to see if I can do it so I can rebuild core.lvl (I noticed BattleBelk had munged scripts for his "Interface Tool", and I noticed none of these scripts shipped with BFBuilder).
I DO NOT need the raw files (.wav, .tga etc), but the munged files (ie .texture, .font etc)
I DO NOT need the raw files (.wav, .tga etc), but the munged files (ie .texture, .font etc)
- Teancum
- Jedi Admin

- Posts: 11080
- Joined: Wed Sep 07, 2005 11:42 pm
- Projects :: No Mod project currently.
- xbox live or psn: No gamertag set
- Location: Indiana
Re: Extracting munged from LVL files?
Just the extractor on SWBFfiles.
- giftheck
- Droid Pilot Assassin

- Posts: 2218
- Joined: Mon Jan 19, 2009 5:58 pm
- Projects :: Star Wars Battlefront Anniversary
Re: Extracting munged from LVL files?
It doesn't extract fonts (although it recognises they're there).
Is there a fontmunge tool available?
Is there a fontmunge tool available?
- Teancum
- Jedi Admin

- Posts: 11080
- Joined: Wed Sep 07, 2005 11:42 pm
- Projects :: No Mod project currently.
- xbox live or psn: No gamertag set
- Location: Indiana
Re: Extracting munged from LVL files?
If there is it'd be in /BF[1 or 2]_tools/Tools/Bin
- giftheck
- Droid Pilot Assassin

- Posts: 2218
- Joined: Mon Jan 19, 2009 5:58 pm
- Projects :: Star Wars Battlefront Anniversary
Re: Extracting munged from LVL files?
That's just it, I don't believe there was. I thought about seeing if I could use the BF2 FontMunge, but I don't think it will work. Also, the fonts were not shipped with BF1. Shame the extractor was never finished.
EDIT: Is it possible to do a shell recompile?
EDIT: Is it possible to do a shell recompile?
- Teancum
- Jedi Admin

- Posts: 11080
- Joined: Wed Sep 07, 2005 11:42 pm
- Projects :: No Mod project currently.
- xbox live or psn: No gamertag set
- Location: Indiana
Re: Extracting munged from LVL files?
Nope. Shell, Core and Ingame edits would be hackjobs at best.
-
BattleBelk
- Private First Class
- Posts: 77
- Joined: Thu Jun 28, 2007 7:08 am
- Projects :: No Mod project currently.
- xbox live or psn: No gamertag set
- Location: Russia
- Contact:
Re: Extracting munged from LVL files?
here is specification for lvl file format:
http://personal.riley-man.com/swbf/edit ... ormat.html
munged chunks can be extracted manually by hexedit but its a lot of work so I made scirpts for 010 Editor and extarcted all chunks
I alredy have all chunks for core.lvl
http://personal.riley-man.com/swbf/edit ... ormat.html
munged chunks can be extracted manually by hexedit but its a lot of work so I made scirpts for 010 Editor and extarcted all chunks
I alredy have all chunks for core.lvl
- Teancum
- Jedi Admin

- Posts: 11080
- Joined: Wed Sep 07, 2005 11:42 pm
- Projects :: No Mod project currently.
- xbox live or psn: No gamertag set
- Location: Indiana
Re: Extracting munged from LVL files?
NICE! Now that is possible. More work, sure, but possible.
The 'short end' is this:
1-Make a mod map, localize EVERYTHING you need to localize for the whole game (I'd recommend just copying over SWBF2's localizations and starting there)
2-Copy the chunks out of the core.lvl into the main core.lvl
Yeah, sounds easy, but I realize it's not. I'm just saying it's possible now. No need to rebuild all the extra crap.
This leads me to a question on the LVL format though -- Are the files stored on a chunk-by-chunk basis, or is there a master table with file sizes and offsets in at the beginning of the LVL file (the site didn't go into that much). If it's just one chunk right after another then that makes life incredibly easy. I don't know how I forgot about this site. Looking at it now makes so much more sense then it did 2 years ago, and will help a lot with the Xbox mod.
*EDIT*
Looks like we can manage hex replacement, but do we need to change the overall filesize in the header? Xentax thinks we do:
http://wiki.xentax.com/index.php?title= ... ront_LVL_1
The 'short end' is this:
1-Make a mod map, localize EVERYTHING you need to localize for the whole game (I'd recommend just copying over SWBF2's localizations and starting there)
2-Copy the chunks out of the core.lvl into the main core.lvl
Yeah, sounds easy, but I realize it's not. I'm just saying it's possible now. No need to rebuild all the extra crap.
This leads me to a question on the LVL format though -- Are the files stored on a chunk-by-chunk basis, or is there a master table with file sizes and offsets in at the beginning of the LVL file (the site didn't go into that much). If it's just one chunk right after another then that makes life incredibly easy. I don't know how I forgot about this site. Looking at it now makes so much more sense then it did 2 years ago, and will help a lot with the Xbox mod.
*EDIT*
Looks like we can manage hex replacement, but do we need to change the overall filesize in the header? Xentax thinks we do:
http://wiki.xentax.com/index.php?title= ... ront_LVL_1
-
BattleBelk
- Private First Class
- Posts: 77
- Joined: Thu Jun 28, 2007 7:08 am
- Projects :: No Mod project currently.
- xbox live or psn: No gamertag set
- Location: Russia
- Contact:
Re: Extracting munged from LVL files?
It's chunk-by-chunk basis and chunk table in a .req file
lvl file can have sub-lvl chunks or just sub-chunks, for example textures for fonts wrapped in .font chunk
some munged files also generates after munge own req file wich means they requests other chunks and those chunks will be placed before
duplicate chunks will be ingnored
some chunks has hash instead normal text string (BF2_ModTools\ToolsFL\bin\hash.exe)
lvl file can have sub-lvl chunks or just sub-chunks, for example textures for fonts wrapped in .font chunk
some munged files also generates after munge own req file wich means they requests other chunks and those chunks will be placed before
duplicate chunks will be ingnored
some chunks has hash instead normal text string (BF2_ModTools\ToolsFL\bin\hash.exe)
-
BattleBelk
- Private First Class
- Posts: 77
- Joined: Thu Jun 28, 2007 7:08 am
- Projects :: No Mod project currently.
- xbox live or psn: No gamertag set
- Location: Russia
- Contact:
Re: Extracting munged from LVL files?
LevelPack.exe from mod tool can do it for us just need set correct req file and cmd bat file for munge chunks in lvl fileTeancum wrote: Looks like we can manage hex replacement, but do we need to change the overall filesize in the header? Xentax thinks we do:
http://wiki.xentax.com/index.php?title= ... ront_LVL_1
- Teancum
- Jedi Admin

- Posts: 11080
- Joined: Wed Sep 07, 2005 11:42 pm
- Projects :: No Mod project currently.
- xbox live or psn: No gamertag set
- Location: Indiana
Re: Extracting munged from LVL files?
So let me make sure I understand correctly:
1-We extract the chunks we need
2-We modify req files in /_MUNGED to point to the chunks we've placed there
3-We use LevelPack.exe in a correctly configured .bat file to munge the chunks back into a proper lvl file.
1-We extract the chunks we need
2-We modify req files in /_MUNGED to point to the chunks we've placed there
3-We use LevelPack.exe in a correctly configured .bat file to munge the chunks back into a proper lvl file.
-
BattleBelk
- Private First Class
- Posts: 77
- Joined: Thu Jun 28, 2007 7:08 am
- Projects :: No Mod project currently.
- xbox live or psn: No gamertag set
- Location: Russia
- Contact:
Re: Extracting munged from LVL files?
yes
sometimes even not need extract original munged chunks as they was before lvl pack, possible cut blocks between needed chunks and set req file like this:
In this req I have files:
raw1.block, raw2.block, raw3.block - raw data blocks between my munged textures.
and for all extracted chunks/blocks need add 8 byte header
4 byte - ucfb
4 byte - integer (size) of following bytes
sometimes even not need extract original munged chunks as they was before lvl pack, possible cut blocks between needed chunks and set req file like this:
Hidden/Spoiler:
raw1.block, raw2.block, raw3.block - raw data blocks between my munged textures.
and for all extracted chunks/blocks need add 8 byte header
4 byte - ucfb
4 byte - integer (size) of following bytes
- giftheck
- Droid Pilot Assassin

- Posts: 2218
- Joined: Mon Jan 19, 2009 5:58 pm
- Projects :: Star Wars Battlefront Anniversary
Re: Extracting munged from LVL files?
So, it is actually possible to build a new core.lvl for BF1? Cool, I wish I knew how to extract these chunks correctly and build the .reqs for them.
