$lightmap2 ?


(Charmin Deluxe) #1

You could set up a shader to reference $lightmap and $lightmap2, with $lightmap2 having an rgbGen wave function on it to simulate a flickering light. Q3Map would do all the dirty work of figuring out which/when/where to use this modified shader, and create any necessary subshaders.

one guy send me this information within email. perhaps you can explain me what you can do with this exactly. my english isn very good and i understand as much as with using this shader its possible to create new lightstyles? will it change the lighting of models/other textures stay near this shader?


(ydnar) #2

JK2 and SOF2 have native support for light styles. No need for shader hacks.

Q3, RTCW, and EF do not. I sort of got lightstyles working, but it’s a brutal hack that only works on tiny levels.

y


(Charmin Deluxe) #3

k but is it possbile to create new light styles for jk2/sof2? is it dependent on the compiler or the game code?


(Fracman) #4

Does it mean you can only use two different lightstyles?
I tried using two times the same lightstyle but what I wanted to do did not work.


(ydnar) #5

JK2/SOF2 support up to 4 styles per surface. One is reserved for the static lighting (style 0).

You don’t have to do anything special with your shaders, other than ensure the lightmaps are the first stage.

y


(JIM_BOB7813) #6

Hi

I have read that in sof2 mp, you can while in-game have lights that turn on and off, when triggered by a player.
There is a document provided with the SDK. It says this:

"A dynamic light is a light that changes while in the game. This can be as simple as turning a light on or off, or having a light that flashes.

In order to turn a light on or off it simply needs to be targeted and therefore requires a targetname."

I connected a light to a func_button, one to a func_door. But the light doesn’t change when they are triggered.

Do I need to assign a Style to the light, or is there something special about the compile?

I am using q3map2 v2.5.3


(MuffinMan) #7

you need to place a dynamic light not a normal light, then it will work, dlights are in the same menu in radiant


(JIM_BOB7813) #8

I can’t see “dynamic light”. All I have is “light”.
The light entitiy info menu says: q3map_non-dynamic.
It’s spawnflags 16. But that doesn’t change anything.


(Fracman) #9

In GTKRadiant (1.2.11), I also only see the normal light entity.
Where is the dlight?

And only in SP_entities.def, there is a misc_dlight.

Is it again a SP / Not_in_MP problem?


(MuffinMan) #10

hmm i have radiant 1.2.13 but i doubt that it is missing in 11, it’s under corona and is named dlight and it’s definitely working in mp, i already used it for a flickering light…


(Tigris) #11

And I always thought JK2 and SOF2 had the same light code…
Guess not :frowning:


(JIM_BOB7813) #12

I have 1.2.13 too, and I can’t see dynamic lights.
MuffinMan, can you please make a .map for us with a dynamic light in it.

The sp_entities.def says this:

“targetname” to indicate a switchable light
“style” to specify a specify light style, even for switchable lights!
“style_off” light style to use when switched off (Only for switchable lights)

So what style is a light when it’s turned off?

And the info in my first post came from a document called “SoF2_MP_Maps”


(MuffinMan) #13

well i can do that but it would be for rtcw, send me an email if you need it to muffinman@wolfproject.net


(Emon) #14

I’ve found that misc_dlights only work on MD3s. Perhaps if you had like a large chunk of outdoor terrain made of MD3, you could have cool dynamic lights. But… MD3 terrain… yeeughh…


(JIM_BOB7813) #15

Thank you for the help guys. But I think i’ll give up on the dlights.


(shadowspawn) #16

use external lightmaps. we even have a few levels that have different lightmaps depending on game mode, since some statics cast shadows and those statics don’t exist except in some gametypes, or when they are destroyed.

call it what you want, but it works and you can do it in larger areas as well.

http://www.shadowspawn.net/temp/flickering2.avi