Search Unity

Static Model goes Black when Lighting is Baked

Discussion in 'Editor & General Support' started by tommywright, Jun 22, 2012.

  1. tommywright

    tommywright

    Joined:
    Jun 21, 2012
    Posts:
    23
    I have a super simple scene with a .blend object UVed with a texture, sitting on a terrain. The .blend object (a house) is set to static. I added a directional light and turned on shadows (for baking). When I bake the lightmap, the object turns black.

    Also, when I hit play, the house jumps to 0,0,0 and leaves it's shadow back where I placed the house in engine. **edit** turning off animation fixed this.

    What am I doing wrong here?
     
    Last edited: Jun 22, 2012
    MuziburRahman likes this.
  2. tommywright

    tommywright

    Joined:
    Jun 21, 2012
    Posts:
    23
    I FINALLY figured this out. You have to select the model in the Project pane and turn on "Generate Lightmap UVs".

    Right now it is giving me both lightmap and vertex lighting. How do I turn off vertex lighting?
     
  3. tommywright

    tommywright

    Joined:
    Jun 21, 2012
    Posts:
    23
    This is not a very lively community, is it?

    If anyone knows how to turn off vertex lighting so that low vert models don't look like poop, let me know.
     
  4. Khyrid

    Khyrid

    Joined:
    Oct 8, 2010
    Posts:
    1,790
  5. Jaimi

    Jaimi

    Joined:
    Jan 10, 2009
    Posts:
    6,208
    you change the lighting model on the camera - vertex lit, forward, deferred. if you don't want a model to have lighting, change the shader on the material to an unlit shader.
     
  6. tommywright

    tommywright

    Joined:
    Jun 21, 2012
    Posts:
    23
    Thank you for your answers. I think what I might be seeing is crappy lightmapping rather than crappy vert lighting.