Converting a map's overgrowth to static objects

Information and tutorials related to modding BF2.
Post Reply
Outlawz7
Retired PR Developer
Posts: 17261
Joined: 2007-02-17 14:59

Converting a map's overgrowth to static objects

Post by Outlawz7 »

Rhino's 3ds Max lightmapping tutorial describes a way to convert overgrowth to static by lightmapping an object so editor temporarily converts overgrowth to static and then selecting everything on map via screen selection which is a lengthy, frustrating process that can be undone by accidentally deselecting or a classic editor crash due to performance.

Fortunately there is a faster way to do this.

For this you obviously need editor and a map which has overgrowth set up that you want converted.

1. Backup

Backup the following files in map's folder:
  • editor/gameplayobjects.con
  • editor/layer.con
  • ambientobjects.con
  • staticobjects.con
  • Gamemodes folder
These will get changed in the process or are simply in the way.

If your map doesn't have an AI folder with an ai.ai file in it, copy it from a map that does.

2. Run editor

Run editor, load your map.

Go to Tools>Add-in Manager and load Singleplayer Editor plugin if not loaded already.
Image

Place a combat zone counter-clockwise with Used by Pathfinding enabled.
Image

Switch to Singleplayer Editor and click Generate Pathfinding.
Image

This action will create a GTSData folder in your map (this is used for creating AI support for your map, but not doing that here) and more importantly, in the process it'll convert your overgrowth to statics.

Switch to Level editor and save and you should now have a new staticobjects.con with all your overgrowth in it.
Saving in Level editor will write/overwrite GPO and statics, that's why we backed them up.

You can now change or remove your overgrowth.

You can combine this new staticobjects.con with old one or load it separately or rename etc.
Last edited by Outlawz7 on 2019-03-31 10:35, edited 2 times in total.
Image
Gatto
Posts: 11
Joined: 2021-04-27 18:56

Re: Converting a map's overgrowth to static objects

Post by Gatto »

That's incredibly helpful, thanks.

I was having trouble lightmapping my overgrowth. The statics lightmapped perfectly.
I had no combat zone on my map (don't use them because it's a sp only mod).
Using your method I've converted overgrowth to statics and am re-lightmapping. 8-)
Post Reply

Return to “Modding Tutorials”