Forum breadcrumbs - You are here:ForumCommunity Boards: Hammer and ModdingLighting
Please or Register to create posts and topics.

Lighting

Page 1 of 2Next

So, my problem is: I have a room with lightning in it. In the room is a panel door as you can see that opens. When it's closed you don't notice there is one. When it's open the lighting is kind of fucked up. How can I get this fixed?

Also, if you look at the big door on the right the wall behind it is also bright, how can you make the light changes dynamically when you play?

Naamloos.png

The light you have is a static light. That means that it is calculated once when compiling to then never be calculated again. When the panel is closed in it's original state and you only have that one static light in front of it, the compiler "thinks" that the light will never be shining behind the panel.

You could either have the panel start open - so the light shines behind it - and add a logic_auto that closes it OnMapSpawn.

Or you could add another light behind the panel.

For more about lights and dynamic light sources, read this.

Static lights are baked in when you compile, the way I get around this is put the static lights furthur away from the panels (so the lighting difference is negligible) and use an env_projectedtexture to brighten it up.

Image
PortalStories.com
"Oh, in case you got covered in that repulsion gel, here's some advice the lab boys gave me: DO NOT get covered in the repulsion gel."

Thank you, just what I needed :)

It's almost there bro, need some little development.....
Better add another light behind the panel.

____________________________
The way to get things done is not to mind who gets the credit for doing them.
Benjamin Jowett's survival knives

The first case is solved.

Now another one. I have a light_dynamic in my map and I want to change the Appearance when I run in a trigger_once field. I do OnTrigger mylight style 9. When I go ingame and I run in the trigger I get this error:

Quote:
!! light_dynamic(lightdraaien,style) doesn't match type from trigger_once()

I don't get what I'm doing wrong since I followed this page: https://developer.valvesoftware.com/wiki/Light_dynamic

You're sure the param is entered in the "param" field, not the "delay" field? I've made that mistake so many times now.

Falsi sumus crusto!

Be careful when using light_dynamic. It may be not as laggy as it was once since computers are faster today, but it still can look very ugly.
If the light you want to change doesn't change it's position, use a normal light entity, give it a name and change it's pattern/style there.

Careful: More than 3 named lights shining on one surface causes bugs.

@FelixGriffin: I'm sure it's in the param field.

@Skotty: I might try to change the lights to normal ones again and see how my lighting turns out.

The normal ones work out, but I still can't have a custom flickering on them or chaning the color now with a trigger.

Page 1 of 2Next