how to make pitch-black areas?

mistertilapia

L1: Registered
Jul 24, 2016
17
4
i am making a map which involves a train disappearing into a tunnel. i am hoping to create a pitch black area for the train to enter and disappear into blackness.
such an area exists on mvm_bigrock, where bots emerge from a foggy, dark cave after spawning:
20160808132427_1.jpg
please let me know if you have ideas on how i could replicate this.
 

LeSwordfish

semi-trained quasi-professional
aa
Aug 8, 2010
4,102
6,597
There's two things you want for this: The ToolsBlack texture always appears as pitch black. You can use this to create a black area (it's what the back of that tunnel will be) and you can use a black gradient overlay on the textures next to it to make them seem to fade to black.

You can also use blocklight - texture a whole brush in tools_blocklight and it will block all light. It's a difficult effect to make natural, but play around with it.
 
Jul 6, 2015
1,425
820
There are 2 textures used, one is an overlay, the other is a tool texture.
The first one, is a black and its a tool texture.
upload_2016-8-8_15-56-19.png

Select the back of the tunnel, and use the black gradient texture.
upload_2016-8-8_15-56-51.png

upload_2016-8-8_15-57-8.png

Secondly: Use the black gradient texture as an overlay on the sides of the tunnel.
upload_2016-8-8_15-57-52.png

upload_2016-8-8_15-58-21.png

Expand it and manipulate it how you want.

Edit: Ninja'd but I have pics :D
 
Last edited:

mistertilapia

L1: Registered
Jul 24, 2016
17
4
wow - first of all i want to thank you all for the incredible support. four high-quality responses in just a few hours is something i haven't seen on any other forum.

the tunnel in question is very short because of other landscaping i have to do, and light was getting into the tunnel from both sides.
in the future i'll be using the VMFs but i also do want to learn about the different methods that can be used to create an effect.

thanks davekillerish for the photos - they were very helpful and i think i just about nailed the effect.

does anyone think that some dark fog in the tunnel would make it more convincing?
 

worMatty

Repacking Evangelist
aa
Jul 22, 2014
1,257
999
There isn't really such a thing as 'dark fog'. Unless you are trying to make some kind of shadow monster, darkness doesn't work like the Vashta Nerada out of Doctor Who, where a travelling shadow that is a collective of invisible piranha-like creatures encroaches on alley ways and gutters. Shade happens because there is a lack of light, or it's being obscured somehow, or the surfaces it shines on aren't very reflective.

To achieve a convincing darkness, one must think about the direction and strength of a light source, and the colour and shade of the surfaces it hits. Darker textures reflect, or bounce, less light, so using things like very dark brown wood and piles of coal would help produce a more convincing darkness because they would bounce less light on to each other. Source actually calculates the amount of light that a surface bounces based on its colour, which is why white and very light wall or floor textures in a room make the room seem brighter.
 

UKCS-Alias

Mann vs Machine... or... Mapper vs Meta?
aa
Sep 8, 2008
1,264
816
First to note, bigrock doesnt do ANYTHING to block light, same for rottenburg and coaltown (havent checked others). That effect there is 100% natural to happen there. And as you can see at the back the transition from wall to black is still visible. In rottenburg they however made a solid wall at the back to hide that transition.

Although the overlay method does work, i wouldnt recommend it due to it giving a straight transition. Instead i would recommend light blocking brushes (with gaps of ~16 HU on the sides) since they allow light to pass through in a more natural way. And with small gaps will still quickly result in a dark area.

But even then, it might be worth checking some valve decompiles on how often they used these effects (you might be surprised on how rare these things are there to find)
 

mistertilapia

L1: Registered
Jul 24, 2016
17
4
thanks again for all of the help. i messed around with the overlays until i found a result i was happy with:
20160809183813_1.jpg
one question i have - how can i create a no-entry sign for the tunnel like the one seen on spawndoors? here are a few things i've tried, hopefully someone can tell me what i'm doing wrong:
  • nodraw brush as a func_respawnroomvisualizer with a no_entry texture on it's front face (forced me to associate it with a spawnroom, allowing either blue or red to get in)
  • playerclip brush with a no_entry texture on it's front face (kept players out, but no_entry did not show)
  • playerclip brush with a no_entry texture overlayed onto it's front face (same result as above)
 

Hotel Detective

L4: Comfortable Member
Dec 10, 2014
187
191
thanks again for all of the help. i messed around with the overlays until i found a result i was happy with:
20160809183813_1.jpg
one question i have - how can i create a no-entry sign for the tunnel like the one seen on spawndoors? here are a few things i've tried, hopefully someone can tell me what i'm doing wrong:
  • nodraw brush as a func_respawnroomvisualizer with a no_entry texture on it's front face (forced me to associate it with a spawnroom, allowing either blue or red to get in)
  • playerclip brush with a no_entry texture on it's front face (kept players out, but no_entry did not show)
  • playerclip brush with a no_entry texture overlayed onto it's front face (same result as above)
A hacky way to do it is probably just put two func_respawnroomvisualizers on top of each other there, one set for each team
 

henke37

aa
Sep 23, 2011
2,075
515
You can just take the existing no_entry material and tweak the material proxies to not care for the team filtering.