Game Development Community

Tunnels through terrain!

by FruitBatInShades · in General Discussion · 08/18/2004 (2:28 am) · 52 replies

Sorry to post this in general but I saw a thread a while ago on DIF's underground and the terrain cutting through them at the entrance. I cannot find it again :(
I have made a tunnel I need to go through the ground but the terrain stops me entering the tunnel. Anyone got any ideas where I'm going wrong? It's just a tunnel DIF that is placed below the terrain level with the entrance outside the terrain.
#21
01/09/2005 (1:17 pm)
It digs when i do showTerrainInside for me!
#22
01/09/2005 (2:27 pm)
This seams like a weird function to me... why would showTerrainInside remove terrain, would it not be called donotshowTerrainInside? When I click on this funcition it does nothing...
How is this function implemented and what was it originally intended for?
#23
01/09/2005 (2:35 pm)
Lyle,

You set showTerrainInside to "off/false" thus not showing the terrain inside the interior. If it's set to "on/true", then terrain *will* show inside.

...that's how I understand it.
#24
01/09/2005 (2:49 pm)
Bryce, try walking through the terrain inside your interiors. You won't beable to get through because showTerrainInside stops the terrain from rendering while your inside of the interior.
#25
01/10/2005 (7:09 am)
I have Torque 1.3 and lighting pack 1.2. Whenever I use set empty in the terrain editor for a brush size under 5x5, it never seems to work, at least it doesn't seem to clear the tile.

Is their a fix for this?
#26
01/11/2005 (8:29 am)
The only time I see terrain not disapearing is when you set empty on flat terrain, the terrain will still appear to render over those spots.
#27
02/09/2005 (1:51 pm)
@Fruit

Yes it does work, I'm using it right now.
#28
02/09/2005 (1:56 pm)
Set empty is the most reliable solution for this task. Culling terrain visibility does not cull terrain collision. Only set empty will cull the collision, it will also allow you to have the entrance to your tunnel outside or near the edge of your first portalized zone.
#29
02/09/2005 (2:13 pm)
@will: sorry, didn't see your screenshots until now. So you can move through this tunnel to the other end?
#30
02/09/2005 (5:02 pm)
Bryces method doesn't work the terrain dissapears but it is still there. so the set empty works best (I have used it and doent have problems)
#31
02/09/2005 (7:08 pm)
@Dirk, Yes... you can go inside that tunnel and walk through the hill/terrain and out through the hole on the other side.

All you have to do is use the Set Empty brush and punch out the holes in the sides of the hill and then stick your tunnel in.

Are you having trouble doing this?
#32
02/09/2005 (10:20 pm)
Hence the name "Set Empty"

This is it's whole purpose is life guys. :)

If your punching holes or sticking things in terrain without using this, your not doing it correctly.
#33
02/09/2005 (10:27 pm)
@will: unfortunately, yes. On the upside it's obvious that I missed 'SetEmpty', so I am going to try again :-). Thanks for the insight!
#34
02/10/2005 (9:54 am)
I've been using set empty for this purpose and had a question about it. I have a tunnel that is not square, but set empty removes a square at a time. So I end up with an opening, but it doesn't match up with the tunnel exactly. Setting the brush to "circle" doesn't seem to change this.

Is this a limitation of the terrain in TGE or is there a way to make a non-square opening in the terrain?

I guess if it is a limitation, I just need to make the tunnel opening exactly the same size and shape as a 1X1 terrain brush or a 3X3 brush if I want a larger tunnel. Is there also a 2X2 brush - I don't see it on the menu?

Is the terrain in TSE going to be different in this respect?
#35
02/10/2005 (11:30 am)
@ Dave I just started messing around with this after reading the thread. It seems you will just have to adjust the terrain around where you set empty to make it "conform" to the .dif. A good thing to do would probably create some debris .dif's to fill in spots too.
#36
02/10/2005 (8:53 pm)
Well, actually I believe the "showTerrainInside" option helps here...

The idea is that if the opening doesnt match up exactly its okay... because this option will make it so that you cant see any squares poking inside the interior/tunnel. Therefore allowing you to create a perfect hole (visually).

(but remember, the collision is still on those pieces of terrain even though they dont show, so you have to make sure they're out of the way of the player.)
#37
02/10/2005 (11:56 pm)
Dave, I put a subway in my map and didn't have any openings around it after using "set empty". Didn't even have to adjust the terrain around the opening either or use "showTerrainInside".

All I did was that I placed the .dif where I wanted BEFORE I used set empty.

Then for set empty I used a 1X1 boxed terrain brush. Don't know if it's just me but when I was hovering the set empty brush over the terrain that was inside the subway, it was adjusting itself and changing it's shape from a square to whatever the terrain was. And with each click, the terrain was dissapearing but ONLY inside the subway.

Hard to explain so give it a try.

Also, make your tunnel walls thick in case you still need to adjust the terrain around it. Pretty much what Lyle said in his post above.

Nick
#38
02/15/2005 (11:16 pm)
When I use 1x1 size Brush, it is so big that it makes huge gaps inbetween my DIF and the terrain. Even if I move it around after that, there is no way to get it snug against the DIF. There is just a huge whole. Is there a way (besides adding little models around the DIF) to get rid of these massive holes?
#39
02/16/2005 (10:24 am)
If the 1x1 size Brush is too big for your tunnel, you may want to make your tunnel bigger... at least make it big enough to close the gap between DIF and terrain.
#40
02/16/2005 (3:48 pm)
Well, it is really a whole building that goes into a cliff and then a little tunnel comes out on the other side. I can't really make it bigger or it will just not be the right scale. I had good luck with one building as the 1x1 brush clipped it just in the right spots. With this building, no such luck. I can't believe there is no other way than to make your DIF bigger >:O I'll keep messin with it....