"Static" lighting on a dynamic model?

  • If you're asking a question make sure to set the thread type to be a question!

MisterYura

L1: Registered
Jan 8, 2010
5
0
Hello again,

I'm still working on that CP map that has a train running through the middle. The map is mostly dark, but the train has a light_dynamic on the front of it, which beautifully lights up the map as the train goes through. The light also lights up the front of the train itself - however, while nice in appearance, just looking at the train causes a severe drop in framerate (200 to 40 fps on my computer, nevermind worse computers). I believe that this is because the dynamic light is recalculated for the train every time the train moves (which is all the time).
I absolutely love the current effect and would like it to remain as similar as possible, but it costs way too much to use the way it is right now. Is there a way that I can create an almost "static" lighting for the train so that it is lit up the same way all the time, while having the dynamic light shine on just for the map itself?
 

MisterYura

L1: Registered
Jan 8, 2010
5
0
It's not quite a matter of needing static lights for the world as much as needing to get rid of the costly constant recalculation of the lighting on the moving train. I need the train model to appear to be lit the same way all the time (even without an actual light shining on it) and for a dynamic light to completely ignore the model.
 

Nutomic

L11: Posh Member
Feb 7, 2009
888
177
you could have multiple "normal lights" but give them a name, and you can turn them on and off. but you would need a lot of them to make it seems smooth and it will tremendously increase the compile time and filesize of the map

Lights with names are always rendered dinamically, that would be even worde performance-wise...

What exact light entity are you using?
 

MisterYura

L1: Registered
Jan 8, 2010
5
0
Lights with names are always rendered dinamically, that would be even worde performance-wise...

What exact light entity are you using?

I'm using a light_dynamic class, parented to the tracktrain:
pitch yaw roll: 1 0 0
entity to point at: n/a
light color: 255 255 255 200
light brightness: 3
inner angle: 0
outer angle: 0
pitch: 0
max distance: 3000
spotlight end radius: 10
appearance: normal​