Is there a way to "kill" a light_environment?

Discussion in 'Mapping Questions & Discussion' started by mmik, Jan 13, 2009.

  1. mmik

    mmik L2: Junior Member

    Messages:
    76
    Positive Ratings:
    0
    I tried adding a name to my light_environment, but it didn't have any inputs when I tried to make an output.

    Is there a way to shut off/kill a light_environment?
     
  2. A Boojum Snark

    aa A Boojum Snark Toraipoddodezain Mazahabado

    Messages:
    4,769
    Positive Ratings:
    5,535
    No. In fact the entity does not even exist in the final map, as it's used to calculate lightmaps and is then removed (which is the same as a light/light_spot without a name).
     
  3. mmik

    mmik L2: Junior Member

    Messages:
    76
    Positive Ratings:
    0
    Ok, I guess my next question is, how taxing would it be for a rather large door to move over my map, blocking out all sunlight? D:

    Are there any more rational ways to do this?
     
  4. A Boojum Snark

    aa A Boojum Snark Toraipoddodezain Mazahabado

    Messages:
    4,769
    Positive Ratings:
    5,535
    That wouldn't actually do anything. As I said, light_env lighting is calculated at compile and then that's that. There is no way to change it while running the map. There is no light being actively cast for the door to block.

    The only possible way to fake it would be a ton of light_spots trying to fake sunlight, but it would look poor and you would probably run into the entity limit (since named lights stay in the map to be toggled) long before you had it looking even halfway decent. Not to mention you would be doubling the amount of data needed for the lightmaps.
     
  5. Earl

    Earl L6: Sharp Member

    Messages:
    284
    Positive Ratings:
    37
    In the goldsrc engine it was possible to have flickering/blinking/toggled lights. Isn't it at least possible to have a toggled light in source? He could just create a very bright constant attenuation light far away from the map.
     
  6. A Boojum Snark

    aa A Boojum Snark Toraipoddodezain Mazahabado

    Messages:
    4,769
    Positive Ratings:
    5,535
    Yeah, but it would have to be really far away for it to not be noticable as not coming from the sky. That would result in a lot of dead sky space to get it that far off.
     
  7. Pseudo

    Pseudo L6: Sharp Member

    Messages:
    319
    Positive Ratings:
    149
    With constant attenuation the light is unaffected by distance so I don't think it would have to be an extreme distance away. A simple light entity could be toggled. Although if this is used for the entire map I'm not sure how the performance would be.
     
  8. Acegikmo

    aa Acegikmo

    Messages:
    555
    Positive Ratings:
    493
    It would have to build the lightmaps for every surface the lights hit twice.
    Would take ages to compile especially with HDR
     
  9. A Boojum Snark

    aa A Boojum Snark Toraipoddodezain Mazahabado

    Messages:
    4,769
    Positive Ratings:
    5,535
    I'm not seeing how you could make it appear as all light is coming from the same angle, rather than a point somewhere above the map. Wouldn't it still cast shadows with constant? and if it didn't... that would be just as weird for the sun to not be making shadows.
     
  10. TotalMark

    TotalMark L6: Sharp Member

    Messages:
    331
    Positive Ratings:
    40
    [​IMG]
    [​IMG]
    [​IMG]

    I tried some stuff with a "light" set to "constant 1" and a orange white light. It's not too far from the skybox. Stepping into the gray area shuts it off.

    There is still dropoff though.
     
  11. mmik

    mmik L2: Junior Member

    Messages:
    76
    Positive Ratings:
    0
    Hey, I got exactly what I needed with a block-light brush. Thanks for the support, though. Real educational, guys.
     
  12. teddyruxpin

    teddyruxpin Sr. Hygiene Technician

    Messages:
    83
    Positive Ratings:
    26
    You can also make some adjustments to the HDR lighting using a tonemap controller but I have found when you use it to kill or change the colors of the lighting you get very odd shadowing affects and complete and utter darkness in areas where you can not see a brush vs open space.

    -Teddy