Still in UNITY 5 - Unbelievable: Spotlight Shadow cut off at "close" distance.

Edited: I downloaded Unity 5, and tested it there. Still the same embarrasing and immersion-killing bug. The following text is the original question#

Edit No 2: Updated to Unity 5.1! No fix or recognition of that bug anywhere. I got no response from my bug report. What went wrong in Unity?#

#Edit No 3: I finally reached someone from Unity by reporting a completely unrelated bug in another ticket and asking them wtf is up with my report. It has been handed to the Developers now and will be fixed in the future. FINALLY. After 6 Years they started to LOOK into it.#

#Unity 5.1.2p3: still not fixed#

Hi, this is my 3rd question here, I only post questions I can’t find an answer to on Google.

The only entry relevant is another post on this forum but it is over one year old now and has no comments.

Here’s my Problem:

For any Spotlight that is closer than some value, which seems to be corelating with the range, to an object, the object’s shadow starts to get clipped/cut off.

For example:

I have a spotlight parented to my camera, no cookie, no script attached, nothing fancy attached. It is a plain spot light.

Spotlight has range 10. When moving it close to an obstacle, at some point the shadow of the obstacle starts clipping into the surface it is projected on. When moving even closer to the obstacle, the clipping continues until the shadow can’t be seen anymore.

When increasing the range of said light, the clipping occurs earlier.
I made a video to demonstrate it:

This video might be more useful to spot the bug:
Please answer if you know what causes this problem. Thank you.

try seeing if the shadow distance and cascade settings in quality helps.
From what the video shows though, it looks like the near proximity is causing the
Light objects cone to penetrate the object. Thus, from the perspective of the
Engine, the light is shining from beside or behind those shelves.

Relax. People lose interest in helping if you’re combative.

Everybody, I’m sick of it now. Since that Unity employee told me, they would update the spotlight inspector to show the near clip value but it will NEVER be below 0.02f I am officially banning spotlights from everything I do in Unity.

Thank you Datapax for your input!

My friend, I am facing the same nightmare as you and I also think this is ridiculous and the dev’s really have to get rid of this ASAP - it is just so annoying and painful for the eye and for my brain being unable to fix it.

However, I came up with a “FIX” for this problem and I would like to share it with you and others that can end up on this thread with this problem. So here is a little step by step for everyone, until they fix this bug from our worst nightmares ;D

  1. Get a 3D modelling program, 3D MAX / Maya / Blender … whatever you
    like and want.
  2. Create a cylinder and make it hollow, so it represents the mesh of
    a real flashlight. I put a small box
    inside of the flashlight so I can
    use it later for a reference to
    attach the light. Finally - export
    and import to Unity.
  3. Attach, scale and position your flash light as you like.
  4. In the inspector be sure that you configure your cylinder “Mesh
    ” to cast “Shadows
    ” and disable receive
    shadows. (this will hide the object
    and only leave us with the light
    effects, if you like it otherwise
    please feel free to configure as you
  5. Attach a “Point Light” object to your “box” reference that
    you created earlier.
  6. Set up the light as you like (range, color, intensity, shadow
    types and etc.
  7. Don’t turn off your original “Spotlight”. Instead just set the
    Shadow Type to “No Shadows
    but leave the rest as you had it
    before. This way you still use the
    cookie texture and light settings if
    you had one before. It is your
    choice if you want to turn it off or
    change the settings in another way,
    but I recommend to keep it so it
    looks pretty much as intended.

This should be enough to have a nice looking flashlight with proper shadow mapping and no more “cutoff”. You can adjust your settings even more if you want to reach a better effect and set your lights properly for your scenes. Be sure to review all the settings and polish everything to improve this effect.
I hope this helps till we get some solution from the dev’s.

Best regards and good luck to all. :slight_smile:

The only thing I found that helps at least reducing this problem is setting the range of that spotlight to much lower value, for example 5 (and you already know that). After that, you might increase light intensity a bit, just to get back similar level of light.
Like LSPressWorks said, it’s definitely happening when cone penetrates the object.