Page 1 of 2

Create "holes" in the Heightmap for tunnels?

Posted: Thu Sep 27, 2012 8:59 pm
by Swaffy
I just thought of this idea. I understand how hard it is for people to make tunnels in this game, how they need to "recreate" the map's surface onto the 3D model of the tunnel so that it fits well with the Heightmap and its texture.

But is there a way to "delete" two squares in the heightmap that are some distance apart, then to have the tunnel go under the heightmap's first hole and back up through the second hole? So, in other words, the players would be able to walk underneath the map on a StaticObject (the tunnel object), and so they won't fall into the abyss. I would think this can make tunneling easier for mapmakers, instead of them having to lower part of the heightmap a few miles to put the tunnel object on top.

Re: Create "holes" in the Heightmap for tunnels?

Posted: Fri Sep 28, 2012 8:02 pm
by Senshi
This only is implemented in the Battlefield Vietnam engine (vanilla, even), as far as I know. Any attempt to replicate that in BF42 led to crashes or simply a filled heightmap, as the engine expects a continous heightmap and there simply is no code to parse a certain value into a "blank" terrain pixel. It's easy to do codewise before compiling, but if it's not implemented, you can't fix it without a serious exe hack.

Re: Create "holes" in the Heightmap for tunnels?

Posted: Sat Sep 29, 2012 1:47 am
by Swaffy
Okay. I thought the heightmap acted similar to a 3D model, with faces and a texture attached to them. Good to know, though.

Re: Create "holes" in the Heightmap for tunnels?

Posted: Mon Oct 01, 2012 3:45 pm
by Diamondback
Your best bet would be to use the Eagle's Nest tunnel objects and retexture them accordingly to the surrounding terrain.

Re: Create "holes" in the Heightmap for tunnels?

Posted: Fri Oct 05, 2012 6:18 pm
by Senshi
The only viable alternative of not using the "lower vertex several miles" is to completely abandon the height map and instead using a static object. Most tunnel maps are rather small, so the usual clipping and LOD issues you get if you e.g. convert El Alamein heightmap to a static won't apply here. Making sure that the correct materials are applied everywhere on the terrain static can be tricky, but for new map projects it's easy to work with.

To convert, best use Rexman's old BF Scripts or my updated 2.76 MDT version if you use 3ds Max versions above 7 (8 through 13, that is).

Re: Create "holes" in the Heightmap for tunnels?

Posted: Wed Oct 10, 2012 4:15 am
by POTAmatt
"Your best bet would be to use the Eagle's Nest tunnel objects and retexture them accordingly to the surrounding terrain."

I did just that when adding an unused BFV tunnel to Iwo Jima. Pathed out for the bots, it adds extra spice to the map:

Image

Re: Create "holes" in the Heightmap for tunnels?

Posted: Wed Oct 10, 2012 6:32 am
by Diamondback
Wow man, very, very nice work, really impressed. You can still see the boundaries of the object outline it, but it's still a very nice addition in a map.

Re: Create "holes" in the Heightmap for tunnels?

Posted: Wed Oct 10, 2012 2:38 pm
by Swaffy
What you can do to further improve the tunnel is to texture the land around the tunnel object so that the textures "fade" more smoothly, opposed to the straight line you see on the edge of the object.

Re: Create "holes" in the Heightmap for tunnels?

Posted: Thu Oct 11, 2012 1:08 am
by Diamondback
There will always be an outline, no matter what you do to conceal it.

Re: Create "holes" in the Heightmap for tunnels?

Posted: Thu Oct 11, 2012 3:36 am
by POTAmatt
Yeah, it wasn't as noticeable at ground level. Haha. Shows you where my priorities are at.