Download

Having difficulty with lighting specific models

Hello, I was having difficulty with the point light (the little lightbulbs that cast soft light in all directions)

my problem is, I cannot get it to discriminate against specific targets. For example, if there was a character standing next to a chair, I would want the light to only affect the character. I played around with the options in the advanced tab, but I saw no where that I could do this. I turned off “affect world”, which is what I want (the light bulb to light up nothing but one thing), but I could not get it to just light up that one thing. It either lights up everything, or lights up nothing. Any tips?

I’m going to add some pictures to show what I mean. here’s the first one: blob:http://imgur.com/c891dda5-186a-49d1-b0cf-7b12ca8bf2f4

You’ll notice how dark some characters are when they aren’t in the light. I used red to distinguish them. As you can see, I’ve added point lights to better light characters in the dark. I wanted to make point lights that are locked to characters, following them around and lighting up only them. A point light for character 1 will not light up character 2, or the map, so to speak.

I can always tweak the lighting to not make the characters light up like glow sticks, I’m just trying to get the base idea down. I made another screenshot showing what I want: http://i.imgur.com/x059IlY.jpg

The characters aren’t too bright, but are still somewhat lit. If any of you know how to make point lights discriminate, do you know how to get them to be locked to one character’s movement, and light only that character up?

Hi there!

Have you tried using Lighting channels? That’ll help with lighting only the character and not the environment. But unfortunately I don’t know a way to make each point light actor only affect that specific player.

thanks! I think I got it to work. I can probably figure a way out to make it affect only that player

Hey, I had another question @Ricewagon

skylight.jpg

I noticed that without any light sources, objects turn pitch black. Is there any way to disable this, so that I still see the texture? As you saw with the earlier pictures, the room was very dark and literally pitch black because it was in a shadow. I want the textures to still be somewhat visible, even when there are no lighting cues.

Use a very dim skylight or emissive materials.

lighting and shadows.jpg

I disabled shadows on the directional light and disabled the skylight entirely. Anything not hit by the directional light is pure black, and I’m trying to reduce that, so that an object receiving no light will still have some texture

Ah! You don’t want to be disabling the skylight, that’s the ambient lighting that will fill in the black sides. https://wiki.unrealengine.com/LightingTroubleshootingGuide#Why_Are_My_Shadows_Black.3F

That’s an excellent resource, and I appreciate you being patient with me so far! However, I cannot seem to get the ceilings of anything to be as light as the surroundings. I know that surfaces not hit at all by the directional light are still made light blue by the skylight, but for some reason the ceilings stay very black.

The shadows guide you posted did offer me a lot of info for adjusting the shadows and I fixed a lot of other problems I was having, so I’ve just got this one last pickle to solve

skylight3.jpg

also, is there anyway to enable these settings?

occlusion.jpg

No worries, glad the link helped you out!

For the ceiling to receive the same lighting as the rest of the environment, go to your Skylight settings and uncheck the ‘Lower Hemisphere Is Black’ box.

thanks! you’ve been a great help!

Always happy to help! And so sorry, I didn’t see your question about the Distance Field Ambient Occlusion. You’ll need to enable ‘Generate Distance Field Meshes’ in the project settings, then restart the editor. Then change the mobility of your Skylight actor to ‘Movable’.

Instructions and more information about it can be found here: https://docs.unrealengine.com/latest/INT/Engine/Rendering/LightingAndShadows/DistanceFieldAmbientOcclusion/#setup

I usually use static lights assigned to lighting channel 1. I also have a blueprint setup for movable lights that use the same/very similar settings as each static light, and place it in the same position. The movable lights are all assigned to lighting channel 2, and so is the player character. For each different instance of the movable light BP, there is an adjustable invisible box collision. Which will deactivate the contained movable light when the character exits the collision box/activates it when they enter. This ensures that there’s only ever two-three movable lights being rendered at any given time. Dynamic objects on the other hand use both lighting channels 1 and 2 and I also have them being lit as static objects until they are triggered, at which point they are switched to dynamic shadows and will then be lit by the movable lights.