how to make pitch-black areas?

Discussion in 'Mapping Questions & Discussion' started by mistertilapia, Aug 8, 2016.

  1. mistertilapia

    mistertilapia L1: Registered

    Messages:
    17
    Positive Ratings:
    5
    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.
     
  2. sevin

    aa sevin

    Messages:
    959
    Positive Ratings:
    661
    Think about it. They don't have any lights back there. It's a long tunnel. Light won't travel all the way down it. They also usually put a brush textured in toolsblack at the back.
     
    • Thanks Thanks x 1
  3. LeSwordfish

    aa LeSwordfish semi-trained quasi-professional

    Messages:
    4,106
    Positive Ratings:
    6,005
    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.
     
    • Thanks Thanks x 1
  4. sevin

    aa sevin

    Messages:
    959
    Positive Ratings:
    661
    Remember that you can always reference decompiled Valve VMF's to help you figure out how they've done things. You should always check those when you're wondering about something that was done in an official map.
     
    • Thanks Thanks x 1
  5. Turnip

    aa Turnip The 80s Vegetable

    Messages:
    1,430
    Positive Ratings:
    795
    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
     
    • Thanks Thanks x 9
    • Like Like x 3
    Last edited: Aug 8, 2016
  6. mistertilapia

    mistertilapia L1: Registered

    Messages:
    17
    Positive Ratings:
    5
    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?
     
    • Like Like x 1
    • Agree Agree x 1
  7. worMatty

    aa worMatty Repacking Evangelist

    Messages:
    1,072
    Positive Ratings:
    833
    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.
     
    • Thanks Thanks x 1
  8. UKCS-Alias

    aa UKCS-Alias Mann vs Machine... or... Mapper vs Meta?

    Messages:
    1,264
    Positive Ratings:
    748
    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)
     
    • Thanks Thanks x 1
  9. MaccyF

    aa MaccyF Notoriously Unreliable

    Messages:
    903
    Positive Ratings:
    1,458
    You can also use a displacement textured tools/toolsinvisibledisplacement with the overlays/black_gradient above a prop (e.g., the rail tracks) so that the overlay darkens the prop as well as the ground.
     
    • Thanks Thanks x 1
  10. mistertilapia

    mistertilapia L1: Registered

    Messages:
    17
    Positive Ratings:
    5
    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)
     
  11. Hotel Detective

    Hotel Detective L4: Comfortable Member

    Messages:
    187
    Positive Ratings:
    189
    A hacky way to do it is probably just put two func_respawnroomvisualizers on top of each other there, one set for each team
     
  12. henke37

    aa henke37

    Messages:
    1,876
    Positive Ratings:
    440
    You can just take the existing no_entry material and tweak the material proxies to not care for the team filtering.