Cave as model: how to make the hole visible through terrain?

Hello everybody,



I’m just new to the JME and was playing around a bit with the JMP, for learning purpose ^^.

I tried to generate a Terrain, worked well. But now i’m facing a problem.

I modelled some simple cave in blender and exported it as .obj, then converted it into j3o. Except of the material all worked well, and is displayed just like needed.

I added it to my scene with the terrain and moved it to the correct position, but as i expected the terrain and the cave overlay each over.

That’s like it has to be, but i’m wondering if there is a possibility that, the inside of the cave is displayed through the terrain (like there is a hole, indeed it’s a cave :wink: )?

Due to my bad english, i may not be able to get it across like i mean it.

After all it should look like a cave in World of Warcraft. (See http://images.wikia.com/wowwiki/images/7/7f/Itharius’s_Cave.jpg).

I would be grateful if someone finds the time to help me.



greetings,

Dragonblade

Just make a dent in the terrain and use the terrain as the floor of the cave maybe.

There isn’t a way to make a hole in the terrain yet. Once jme3 official release goes out I will implement a way to create holes, but for now you will have to create your own way.

You can, for now, select the TerrainPatch that you want to have the hole and change the actual mesh. Just be careful with the LOD techniques it uses.

I was afraid that there exists only such workarounds.

I will try them out.

Thanks for your help.

Edit:

@ normen:

Maybe I expressed myself a bit incomprehensible.

Of course you’re right, a hole is a workaround too. With “I was already afraid that there exist only workarounds”, i meant that it’s actually the case, not that i’m relieved that it’s possible to make a hole. :slight_smile:

I hope, with the edit it’s more understandable.

A hole in the terrain is a workaround too ^^

Perhaps its possible to just make a hole in the full detail mesh by removing those polygons, and keep the lower LOD mesh polys and colour those black as if it was a “dark entrance” from a distance. Unless the LOD ones goes outside the cave model (which I would assume in lower LOD only consisted of whatever entrance objects you have). My next challenge is to generate some caves as well so I guess I will have to learn about this soon. :slight_smile: - Actually I have to learn how to make LOD versions of any objects and figure out how the switch between them works.