Issues making a new Core.lvl

In this forum you will find and post information regarding the modding of Star Wars Battlefront 2. DO NOT POST MOD IDEAS/REQUESTS.

Moderator: Moderators

Post Reply
anyder21
Posts: 4
Joined: Sun Nov 09, 2014 4:56 pm
Projects :: No Mod project currently.
Games I'm Playing :: SWBF1 SWBF2
xbox live or psn: No gamertag set

Issues making a new Core.lvl

Post by anyder21 »

Well, apparently I have some issues making a new core.lvl file for SWBF2.

The created file will have 2.500 Kb, when the size of the original one is larger, so it obviously doesnt work...


Can someone help me with this issue ?

There are no notes or whatever in the munge log
User avatar
Anakin
Master of the Force
Master of the Force
Posts: 4817
Joined: Sat Sep 19, 2009 11:37 am
Projects :: RC Side Mod - Remastered - SWBF3 Legacy
Location: Mos Espa (germany)

Re: Issues making a new Core.lvl

Post by Anakin »

Have you add the stock fonts?? Why do you want to replace the stock core file??
User avatar
AnthonyBF2
Sith
Sith
Posts: 1255
Joined: Wed Aug 21, 2013 3:55 pm
Projects :: PS2+PSP Overhaul

Re: Issues making a new Core.lvl

Post by AnthonyBF2 »

I think the assets in the mod tools do not match the original game file when it comes to the core.lvl's contents.

You can remake shell, ingame, and the mission fine.
anyder21
Posts: 4
Joined: Sun Nov 09, 2014 4:56 pm
Projects :: No Mod project currently.
Games I'm Playing :: SWBF1 SWBF2
xbox live or psn: No gamertag set

Re: Issues making a new Core.lvl

Post by anyder21 »

Well, i know i can mod all that... I'm a Master Modder in SWBFGamers, and i didnt get the title cause of my pretty face ;)

The reason that I want to replace my current core is pretty obvious: I've done it for SWBF1, and so I want my custom one for SWBF2. I'm not sure what that of fonts is...

Does that mean that u cannot get ur custom core.lvl ? I guess that just leaves the alternative to extract all files from the core and remunge or hexedit....
User avatar
[RDH]Zerted
Gametoast Staff
Gametoast Staff
Posts: 2982
Joined: Sun Feb 26, 2006 7:36 am
Projects :: Bos Wars AI - a RTS game
Games I'm Playing :: SWBF2 and Bos Wars
xbox live or psn: No gamertag set
Location: USA
Contact:

Re: Issues making a new Core.lvl

Post by [RDH]Zerted »

There is a proper core.req floating around somewhere on the site. It can be replaced, but I don't think we have optimized versions of some of the stuff. Meaning SWBF2 runs slower with a custom core.lvl.

There's an lvl extraction utility too (I think named extract). You won't get all the files in editable formats, but you'll get a listing on what's in the lvl.
User avatar
AnthonyBF2
Sith
Sith
Posts: 1255
Joined: Wed Aug 21, 2013 3:55 pm
Projects :: PS2+PSP Overhaul

Re: Issues making a new Core.lvl

Post by AnthonyBF2 »

You can see what's in the core.lvl by opening it in hex editor and scanning for any instance of "Luap" each time you see that bit of code, the title of a script is nearby.

You can also hex search for ".tga" to see what textures are called.
This would be nice to accomplish, I'd like to remove annoying "we dropped flag..." blah blag crap.

Edit:
I'm totally mistaken for what core.lvl is used for, there are no ".lua" in there.

Edit again
I found 30 instances of ".xml" extension in the core.lvl
in C:\BF2_ModTools\data_MOD\Common\shaders\PC there are 32 .xmls

I think you need to make a req, and determine which 2 extra xmls are not used.
anyder21
Posts: 4
Joined: Sun Nov 09, 2014 4:56 pm
Projects :: No Mod project currently.
Games I'm Playing :: SWBF1 SWBF2
xbox live or psn: No gamertag set

Re: Issues making a new Core.lvl

Post by anyder21 »

[RDH]Zerted wrote:There is a proper core.req floating around somewhere on the site. It can be replaced, but I don't think we have optimized versions of some of the stuff. Meaning SWBF2 runs slower with a custom core.lvl.

There's an lvl extraction utility too (I think named extract). You won't get all the files in editable formats, but you'll get a listing on what's in the lvl.
It will be really awesome if you could link me to it.
I already have my own LVL extractor, and know how it works ;)
User avatar
AceMastermind
Gametoast Staff
Gametoast Staff
Posts: 3285
Joined: Mon Aug 21, 2006 6:23 am
Contact:

Re: Issues making a new Core.lvl

Post by AceMastermind »

The core.lvl file will only contain files called by core.req.
If you look in core-japanese.req and remove all the non PC and Japanese or obsolete lines, then add the localization stuff from core.req, you'll end up with this (minus the path comments):
Hidden/Spoiler:
[code]ucft
{
REQN
{
"bnk"
"align=2048"
"global" //BF2_ModTools\assets\common\sound\global.sfx
}

REQN
{
"config"
"global" //BF2_ModTools\assets\common\sound\global.snd
}

REQN
{
"font"
"starwars_small" //BF2_ModTools\data_ABC\Common\fonts\starwars_small.fff
}

REQN
{
"loc"
"english" //BF2_ModTools\data_ABC\Common\Localize\English.cfg
"spanish"
"italian"
"french"
"german"
"uk_english"
}

REQN
{
"texture"
"platform=pc"
"cube_normalizationmap" //BF2_ModTools\data_ABC\Common\effects\PC\cube_normalizationmap.tga
"hemisphere_normalizationmap"
"specularspot"
"attenuation_volume"
"linear_ramp"
"specularcubemap"
}

REQN
{
"shader"
"platform=pc"
"normal_shader" //BF2_ModTools\data_ABC\Common\shaders\PC\normal_shader.xml
"interface_shader"
"particle_shader"
"terrain_shader"
"sprite_shader"
"skyfog_shader"
"foliage_shader"
"lightbeam_shader"
"scroll_shader"
"flare_shader"
"sample_shader"
"rain_shader"
"normalmapadder_shader"
"prereflection_shader"
"water_shader"
"stencilshadow_shader"
"shadowquad_shader"
"specular_shader"
"detail_shader"
"ocean_shader"
"refraction_shader"
"decal_shader"
"filtercopy_shader"
"shield_shader"
"bump_shader"
"zprepass_shader"
}

}
[/code]
It looks like we have all the files needed, at least from what I can tell.

You also need to add these under "font"
gamefont_large
gamefont_medium
gamefont_small
gamefont_super_tiny
gamefont_tiny

Your new core.req will look like this:
Hidden/Spoiler:
[code]ucft
{
REQN
{
"bnk"
"align=2048"
"global"
}

REQN
{
"config"
"global"
}

REQN
{
"font"
"starwars_small"
"gamefont_large"
"gamefont_medium"
"gamefont_small"
"gamefont_super_tiny"
"gamefont_tiny"
}

REQN
{
"loc"
"english"
"spanish"
"italian"
"french"
"german"
"uk_english"
}

REQN
{
"texture"
"platform=pc"
"cube_normalizationmap"
"hemisphere_normalizationmap"
"specularspot"
"attenuation_volume"
"linear_ramp"
"specularcubemap"
}

REQN
{
"shader"
"platform=pc"
"normal_shader"
"interface_shader"
"particle_shader"
"terrain_shader"
"sprite_shader"
"skyfog_shader"
"foliage_shader"
"lightbeam_shader"
"scroll_shader"
"flare_shader"
"sample_shader"
"rain_shader"
"normalmapadder_shader"
"prereflection_shader"
"water_shader"
"stencilshadow_shader"
"shadowquad_shader"
"specular_shader"
"detail_shader"
"ocean_shader"
"refraction_shader"
"decal_shader"
"filtercopy_shader"
"shield_shader"
"bump_shader"
"zprepass_shader"
}

}[/code]
You'll need to copy:
BF2_ModTools\assets\common\sound folder
to:
data_ABC\Common

Download this archive and extract the wav files to:
data_ABC\Sound\global\effects

Munge with "Common" ticked in VisualMunge

It might be a good idea to use the Fixed and improved munge files before you start munging.
User avatar
[RDH]Zerted
Gametoast Staff
Gametoast Staff
Posts: 2982
Joined: Sun Feb 26, 2006 7:36 am
Projects :: Bos Wars AI - a RTS game
Games I'm Playing :: SWBF2 and Bos Wars
xbox live or psn: No gamertag set
Location: USA
Contact:

Re: Issues making a new Core.lvl

Post by [RDH]Zerted »

I found where we posted the core.req: viewtopic.php?f=27&t=13685&hilit=core.req I didn't check to see if it matches AceMastermind's.
Here's the LVL extractor: http://starwarsbattlefront.filefront.co ... ctor;32428

If you have your own extractor feel free to post it, even better if you include the source code.
Post Reply