1. Hey there Guest,

    The game servers have moved to semi-dedicated hardware and IPs have changed. Please see front page server widget for up-to-date game server information.

Projected textures?

Discussion in 'Mapping Questions & Discussion' started by eXuaL, Mar 18, 2011.

  1. eXuaL

    eXuaL L1: Registered

    Messages:
    16
    Positive Ratings:
    0
    Hey guys, after my lighting works again i have a new idea, though i'm not sure if this works with tf2.

    Basicly, what i wanted to do is create a env_projectedtexture projecting a texture on a ceiling, now i heard this isnt supported for TF2

    is this true? (main question)



    if its not and someone knows how to make them, could you explain me how to
    this:


    [​IMG]

    if someone might know if this works for tf2, could you explain me how?

    (i've searched google for it myself and haven't succeeded in finding anything on this.)

    Thanks

    eXuaL
     
    Last edited: Mar 18, 2011
  2. absurdistof

    aa absurdistof

    Messages:
    1,242
    Positive Ratings:
    396
    Are you talking about really detailed shadows? For example you would be able to see the fence on the ceiling?

    If yes, then I can answer to the best of my knowledge.

    Basically, seeing as that's a texture, the best way I can suggest that you make that texture cast shadows (well an easy way, a bit sloppy though) is to draw really thin blocklights over the bars of the texture, and lower the lightmap on the ceiling so that the shadows can be more detailed. Lowering the lightmap essentially lowers the area of each unit calculated while VRAD works, or raises resolution of your shadows.

    You might also try just making the grates out of brushwork, whilst lowering the lightmap.

    However, take note: This grate's going to have a dark effect on your map, so if you don't treat it right, it could come off as too realistic/not TF2-ish.
     
    Last edited: Mar 18, 2011
  3. eXuaL

    eXuaL L1: Registered

    Messages:
    16
    Positive Ratings:
    0
    so i guess a block light automaticly emits light, if so i'm going to try that in combination of the ceiling with a lightmap of 4
     
  4. Sgt Frag

    Sgt Frag L14: Epic Member

    Messages:
    1,443
    Positive Ratings:
    356
    You might even need a lightmap of 1 to show that small of detail good. It'll take a lot of file size though.

    Might be better just to turn that tex into a decal and put that on the ceiling.
     
  5. eXuaL

    eXuaL L1: Registered

    Messages:
    16
    Positive Ratings:
    0
    can't i make a brushwork near wall, which is invisible but is still eligible for shadows etc?
     
  6. Sgt Frag

    Sgt Frag L14: Epic Member

    Messages:
    1,443
    Positive Ratings:
    356
    nodraw should work, but if you want to project the light needs to be far enough away to get the effect you want, and it looks like you have lava right below that grate....
     
  7. eXuaL

    eXuaL L1: Registered

    Messages:
    16
    Positive Ratings:
    0
    i got it working, thanks, used nodraw brushes with lightmap scale 1.

    Thanks,

    eXuaL

    /close
     
  8. absurdistof

    aa absurdistof

    Messages:
    1,242
    Positive Ratings:
    396
    Wait, I'm confused.

    You project an image.

    You cast a shadow.

    Are we casting the shadow of the fence, or are we projecting another image entirely?

    If you want to cast shadows, you're going to need something to block the light coming out of the lava, or out of the light source near the lava. This light source should be under the grate if you want it to be the most realistic. In order to block the light, you're going to need to make nodraw or blocklight textured brushes over the texture where the metal is. This will block the light and cast the shadow. However, unless your lightmap is quite low on the brush the shadow is being cast onto (the ceiling) then you won't see a crisp shadow, which I assume you want. So you're going to need to put brushes over the texture (inside it, where the metal is, so players don't run into the brushes), and lower the lightmap to 1-3 on the ceiling to give a sharp unblurred shadow from the grate.

    Derp ninja'd :O
     
  9. markcocjin

    markcocjin L1: Registered

    Messages:
    9
    Positive Ratings:
    3
    eXuaL, if you're trying to be realistic, in the real world, lava won't cast shadows of the grate unto the under slab.

    Lava or coals or any similar glowing objects project a diffused light. Judging from the surface of your glowing material, its distance from the grate, the thickness of the grate, and the grate's distance from the surface projected to, you won't see any shadows.

    A shadow falls off the farther it is from the surface. Even more so if the object is small or thin and the light source is weak and indirect.
     
    • Thanks Thanks x 1
  10. Goudvis

    Goudvis L1: Registered

    Messages:
    8
    Positive Ratings:
    0
    I agree with markcocjin. But it's looking great :)
     
  11. StickZer0

    aa StickZer0 💙💙💃💙💙

    Messages:
    664
    Positive Ratings:
    668
    For the record, env_projectedtextures ARE supported in TF2, but the server must have mp_flashlight set to 1, and the player must have mat_flashlight set to 1. They may not be the exact commands, but here's proof of it working:

    [​IMG]