Prop Lighting Fix

Discussion in 'Mapping Questions & Discussion' started by Xi.Cynx, Sep 6, 2009.

  1. Xi.Cynx

    aa Xi.Cynx Former Alias: †Blade†

    Messages:
    772
    Positive Ratings:
    721
    Hi, I was wondering hwo I would go about fixing this problem below.
    [​IMG]

    I don't know if disabling shadows would still allow proper lighting on it from the lights i have put in there. I would really like to stick with the props and not use brushes either.
     
  2. YM

    aa YM LVL100 YM

    Messages:
    7,099
    Positive Ratings:
    5,739
    Look at the stickies in this forum.

    [ame="http://forums.tf2maps.net/forumdisplay.php?f=12"]Mapping Tutorials & Resources - TF2Maps.net[/ame]

    Stickies are stickied for a reason ;)
     
  3. Xi.Cynx

    aa Xi.Cynx Former Alias: †Blade†

    Messages:
    772
    Positive Ratings:
    721
    Are you talking about this sticky? - [ame="http://forums.tf2maps.net/showthread.php?t=2994"][Tutorial] REMOVING UGLY SHADOWS - TF2Maps.net[/ame]

    If so, that's not what I'm really asking, there isn't an ugly shadow being casted by it, but the prop itself is black cause it's halfway through the ground brush.

    I also tried using Lighting Origin, but that's stopped the lights in there from casting their light on it.
     
  4. JoshuaC

    JoshuaC L7: Fancy Member

    Messages:
    446
    Positive Ratings:
    145
    I had this exact issue in an early version of tomb. Only way I could see how to fix it was to move the models away from the wall.
     
  5. Scotland Tom

    Scotland Tom L6: Sharp Member

    Messages:
    332
    Positive Ratings:
    64
    Yep, YM was talking about that sticky. The problem is probably occurring because the origin of the prop is in shadow, therefore the entire prop is rendered in shadow. I believe the solution you're looking for is described on page 3 of that thread. There's actually a link to page 3 right in the first post.
     
  6. Terr

    aa Terr Cranky Coder

    Messages:
    1,591
    Positive Ratings:
    405
    IIRC it's changing the origin used for lighting (property on the entity) to an info_target placed aboveground. (I suppose an info_null could work too, but haven't tried.)
     
  7. Xi.Cynx

    aa Xi.Cynx Former Alias: †Blade†

    Messages:
    772
    Positive Ratings:
    721
    Hmmm... well I did what he said to do on page three, I did an -final(slow) compile with this light setting instead of the normal one.
    But then I got this error, and the props were still black and the lighting on the ground was all whacked out...

    Code:
    8 direct lights
    BuildFacelights:     0...1...2...3...4...5
    WARNING: Too many light styles on a face at (-183.999985, 1832.000000, -167.000000)
    ...6...7.
    WARNING: Too many light styles on a face at (-568.000000, 1848.000000, 63.000000)
    
    WARNING: Too many light styles on a face at (-440.000000, 1960.000000, -167.000000)
    ..8...9...10 (84)
    BuildVisLeafs:       0...1...2...3...4...5...6...7...8...9...10 (3)
    transfers 445736, max 333
    transfer lists:   3.4 megs
    GatherLight:         0...1...2...3...4...5...6...7...8...9...10 (1)
    	Bounce #1 added RGB(2624, 3735, 5121)
    GatherLight:         0...1...2...3...4...5...6...7...8...9...10 (0)
    	Bounce #2 added RGB(137, 251, 410)
    GatherLight:         0...1...2...3...4...5...6...7...8...9...10 (0)
    	Bounce #3 added RGB(10, 23, 46)
    GatherLight:         0...1...2...3...4...5...6...7...8...9...10 (0)
    	Bounce #4 added RGB(1, 2, 5)
    GatherLight:         0...1...2...3...4...5...6...7...8...9...10 (0)
    	Bounce #5 added RGB(0, 0, 1)
    Build Patch/Sample Hash Table(s).....Done<0.0126 sec>
    FinalLightFace:      0...1...2...3...4...5...6...7...8...9...10 (2)
    FinalLightFace Done
    0 of 0 (0% of) surface lights went in leaf ambient cubes.
    ThreadComputeLeafAmbient: 0...1...2...3...4...5...6...7...8...9...10 (3)
    Writing leaf ambient...done
    Computing static prop lighting : 0ThreadComputeStaticPropLighting: 0...1...2...3...4...5...6...7...8...9...10 (11)
     
  8. Psy

    aa Psy The Imp Queen

    Messages:
    1,705
    Positive Ratings:
    1,465
    Do you have lights that turn on and off?
     
  9. Xi.Cynx

    aa Xi.Cynx Former Alias: †Blade†

    Messages:
    772
    Positive Ratings:
    721
    Nope, I have 4 point_spotlights and 4 light_spots in there pointing in the best direction I thought for it to light up the room. That's it, no other light sources.
     
  10. Xi.Cynx

    aa Xi.Cynx Former Alias: †Blade†

    Messages:
    772
    Positive Ratings:
    721
    okay, so i just made brushes to look exactly like the props so they would light up. But the problem still occurs whenever I use the "youme" compile I get this error and this is how it looks in game.

    Code:
    11 direct lights
    BuildFacelights:     0
    WARNING: Too many light styles on a face at (-445.132629, 1874.151245, -47.000000)
    
    WARNING: Too many light styles on a face at (-494.322510, 1777.909180, -47.000000)
    ..
    WARNING: Too many light styles on a face at (-441.028992, 1888.500000, -46.000000)
    
    WARNING: Too many light styles on a face at (-542.900452, 1659.659790, -46.000000)
    .1...2...3...4.
    WARNING: Too many light styles on a face at (-72.000000, 2168.000000, -167.000000)
    ..5..
    WARNING: Too many light styles on a face at (-183.999985, 1784.000000, -167.000000)
    .6...7...
    WARNING: Too many light styles on a face at (-440.000000, 1864.000000, 63.000000)
    
    WARNING: Too many light styles on a face at (-440.000000, 2040.000000, -167.000000)
    
    WARNING: Too many light styles on a face at (-696.000000, 1544.000000, -167.000000)
    
    WARNING: Too many light styles on a face at (-696.000000, 1448.371338, -163.871536)
    8...9...10 (89)
    BuildVisLeafs:       0...1...2...3...4...5...6...7...8...9...10 (4)
    transfers 430826, max 365
    transfer lists:   3.3 megs
    GatherLight:         0...1...2...3...4...5...6...7...8...9...10 (0)
    	Bounce #1 added RGB(2450, 3489, 4769)
    GatherLight:         0...1...2...3...4...5...6...7...8...9...10 (0)
    	Bounce #2 added RGB(130, 240, 393)
    GatherLight:         0...1...2...3...4...5...6...7...8...9...10 (0)
    	Bounce #3 added RGB(9, 22, 45)
    GatherLight:         0...1...2...3...4...5...6...7...8...9...10 (1)
    	Bounce #4 added RGB(1, 2, 5)
    GatherLight:         0...1...2...3...4...5...6...7...8...9...10 (0)
    	Bounce #5 added RGB(0, 0, 1)
    Build Patch/Sample Hash Table(s).....Done<0.0125 sec>
    FinalLightFace:      0...1...2...3...4...5...6...7...8...9...10 (2)
    FinalLightFace Done
    0 of 0 (0% of) surface lights went in leaf ambient cubes.
    ThreadComputeLeafAmbient: 0...1...2...3...4...5...6...7...8...9...10 (3)
    Writing leaf ambient...done
    Computing static prop lighting : 0ThreadComputeStaticPropLighting: 0...1...2...3...4...5...6...7...8...9...10 (11)
    [​IMG]
    [​IMG]

    But when I do a regular "not so youme" compile all the lighting looks fine.
    So that leads me to the fact that it must be something to do with either.. HDR or the individual vertex lighting thingamabob.
     
  11. YM

    aa YM LVL100 YM

    Messages:
    7,099
    Positive Ratings:
    5,739
    Wait a second, that error only comes from lights that turn on and off... you MUST have some somewhere.... :/
     
  12. Xi.Cynx

    aa Xi.Cynx Former Alias: †Blade†

    Messages:
    772
    Positive Ratings:
    721
    Welp, you wanted proof, here it is... absolutely no on/off lights at all T_T


    Light Properties
    [​IMG]

    Light_Spot Properties
    [​IMG]

    Point_Spotlight Properties
    [​IMG]
     
  13. Terr

    aa Terr Cranky Coder

    Messages:
    1,591
    Positive Ratings:
    405
    As a general rule, none of those lights should have "Name" filled in.

    If they have names, VRAD assumes something might try to turn them on or off at some point (even if you don't have the I/O in your map to do it) and does the extra states anyway.
     
    • Thanks Thanks x 1
  14. YM

    aa YM LVL100 YM

    Messages:
    7,099
    Positive Ratings:
    5,739
    This. Do not ever give a light a name unless you're telling it to do something. The very fact it has a name makes it an on/off light, since you have more than six states in your lightmap (from multiple named lights) you're getting that error.
     
    • Thanks Thanks x 1
  15. Xi.Cynx

    aa Xi.Cynx Former Alias: †Blade†

    Messages:
    772
    Positive Ratings:
    721
    Good deal =) I will remove their names and remember not to give them a name again unless i'm needing them to turn on. thank you all for your time in helping me figure this out.