cluster f@#$ shadow pattern


(Clutch152) #1

three words WTF???

Looks a little odd. thats not how shadows should look :smiley:


(carnage) #2

looks like your shadows are showing on the angular brushwork but its pretty hard to tell from that picture

my best gess is that you need a phong shader to smooth the lighting a little bit if you could post that it would help a lot more


(psyco_mario) #3

:open_mouth: thats the lighting messing up on the triangles of the terrain, happenes to me all the time :stuck_out_tongue:

soz, no idea how you fix it, try the phong thing, or more bounce or summin :smiley: -bounce 90421740 (lol!!! complie time 109471hours+ :wink: )


(carnage) #4

soz, no idea how you fix it, try the phong thing, or more bounce or summin -bounce 90421740 (lol!!! complie time 109471hours+ )

oh yes that would work since you total get rid of the nasty angles in the brushwork that cause the shadow differance thatway (sarcasm)

and it would be so meaningful since all the bounces would keep going for that long as well (more sarcasm) most compiles i do even on big maps have significantly reduced calcaultions on the 4th - 5th pass and by the 8th they dont take too long so i doubt you would greatly increase the compile time


(psyco_mario) #5

woo! im so clever! :smiley:


(Clutch152) #6

what would I apply the phone shader to?

Ive been using the stock compiling options from radiant ive been using
Q3Map2: (test) BSP -meta, -vis, -light -fast -filter

I guess i figured it was enough


(carnage) #7

phong shader, a phone is a device used to cominicate via audio media

try doing some searching for ā€œshaderā€ tutorials there are loads on the net and bound to be a few in these forums


(Graham) #8

http://simland.planetquake.gamespy.com//pages/articles/phongshading1.htm

May be difficult to understand but it’s good.


(Clutch152) #9

ok thx guys i got it looking good but now its just darker lol :smiley:


(Loffy) #10

Yeah, try dirrerent shaders.
If you do a phong shader for the entire terrain, you will have a line ā€œq3map_shadeangle Xā€ in the shader. Try starting wihth X=30, for example. Test it. Then go 50-100 (or 150) in various test-compiles.
Eventually you will have a nice terrain, hopefully.


(Clutch152) #11

yea i already ended up with 60. but now the red light from underground bleeds through in certain spots. its kinda annoying grr. lol. The light underground is comming from the shader of the light strip and only seems to bleed through where i fixed the terrain. I deleted that section of terrain and was gonna have them trenches but i decided to make them tunnels. I only got about halfway around the middle building when i patched the terrain up. So the red light only bleeds through in that area. But now that ive upped the sunlight emited by the skybox its less noticable.


(Loffy) #12

Sometimes when I get light-shinging-through, I place a lamp there. See the terrain in the river to the right of the bridge near the airfield in the map Eagles 2 Ways beta 3.
Another trick I use is to change the sharpness of the lightmap. Select the entire terrain, make it a func_group, give it ā€œlightmapscaleā€ with value lower than 1, e.g. 0.25.


(sodsm live) #13

so far all of my light-bleed-through problems have been fixed by func_grouping the right combination of brushes. it’s trial and error on which brushes to group, mostly becuase i don’t know what q3map2 is actually doing. i can build a room perfectly and have it fit the surrounding structures perfectly with no t-juncs, overlapping/intersecting or partially obscured brushes and still get light bleeding. something to do with merging planes or crossing portals or … i just don’t know but i wish i did.


(Clutch152) #14

well thx for all your help guys. I got it to look more or less how I wanted it by messing around with the shader itself and making the sky brighter. I changed the sky to siwa sky to make it more desertish with no cloud cover :smiley: and added a slight desert fog. Just enough so that if you are standing against backwall you can still see the outlining of the building accross the map. I also moved the default spawn points to underground to help decrese spawn rage :smiley:

LOL try to find the secret room :smiley:

By the way what would be the best way to make rotating red green and blue lights? As in 1 appears and the others dissappear because I know you can’t do it with regular lights because if you add a targetname to a regular light it messes up most of the shaders within range of the light. I wanna add a disco ball to part of my secret room to make one of our clan members happy :smiley:

[EDIT]: Oh I also wanna make all the light bulbs destructible so when you shoot them out the light goes out.


(spaffdog) #15

destructible lights… hmm… thats a tricky one.

aren’t all ilghts pre rendered during the lights compile? having a destructible that emits light then stops when it’s shot out would be good but i’m sure that was one of the many things great about doom3’s new engine. lights and shadows could be calculated in real time. light fitting moves… the light moves with it… I may be wrong but i’m not sure how the q3 engine can do that. that said there are things like the lighthouse in battery. does that move? can’t remember.if it moves it could also be turned off imo.

wow i’m babbling, that ones got me confused and i’d also love an answer :smiley:


(kamikazee) #16

As I said in the other topic: I think it’s hard to do but it might be possible.


(Clutch152) #17

yea if i was to make a brush with a shader that emits light then it to would prolly be renddered during the light compile. the only things that are able to change light during game play are dlighs i believe and i dont know how i would make stay a sloid light without blinking lol. The UT engine could do it no problem :slight_smile:


(WeeBull) #18

I wanted to know how to make a light switch once and someone said it was done in a rtcw map, so I e-mailed the maker of that map and he sent me this:

The setup itself is a bit complicated, but the idea is simple. It will be easiest if i just run through how to build it. Start with your room, and any surfaces that will be affected by any of the lights you wish to turn on/off. Copy all of that geometry and move it directly above, under, right or left of the origional, or as close as possible without obscuring any other geometry. Make the selected brushes a script_mover. Create an origin for it and two path_corners, one where the origin is, the other aligned so the script_mover is in perfect alignment of the origional room. Now you must apply the same texture as in the origional room, but using a special shader for them.

This is a shader i built for the script_mover, using an existing texture in the game.

textures/silo_wall/concrete_c07bcmp_offset
{
qer_editorimage textures/miltary_wall/concrete_c07bcmp.tga
surfaceparm nonsolid
surfaceparm nomarks
polygonoffset

{
    map $lightmap
    rgbGen identity
}
{
    map textures/miltary_wall/concrete_c07bcmp.tga
   blendFunc GL_DST_COLOR GL_ZERO
    rgbGen identity
}

}

Notice i used the polygonoffset parameter, this is the most important one of all them. Also surfaceparm nonsolid, nomarks are necessary.

Now once you have all these aligned properly, go ahead and setup your script_mover. For the scripting here is what i have.

//LightSwap Trigger
lightswitch
{
spawn
{
}

trigger toggle
{
    trigger lightmap toggle
}

}

//LightSwap Lightmaps
lightmap
{
spawn
{
accum 1 set 0
wait 500
alertentity lightbulbs //fixing bug…
wait 500
alertentity sparks
alertentity lightbulbs
gotomarker on 9000
}

trigger toggle
{
    //halt
    trigger lightmap off
    wait 5
    trigger lightmap on
}

trigger off
{
    accum 1 abort_if_not_equal 0
    resetscript
    accum 1 set 1
    alertentity lightbulbs
    alertentity corona
    alertentity sparks
    gotomarker off 9000
}

trigger on
{
    accum 1 abort_if_not_equal 1
    resetscript
    accum 1 set 0
    alertentity lightbulbs
    alertentity corona
    gotomarker on 9000
    alertentity sparks
}

}

This works so the light can be toggled on or off and stay that way until the mover is triggered again. some of the other things ive used are corona’s and light models, as well as sparks for a broken light.
If you still have any questions feel free to drop by my forums whitch are dead and ask a question or just email me back. Hope it works out!

I’ve tested it and it sorta works, you won’t see the light on the walls anymore but the light is still there and when a character stands underneath it, it will still be lit. Maybe it’s useful for you, maybe it’s not, just wanted to let you know :slight_smile:


(Clutch152) #19

thx man. that seems like quite a bit of editing so ill try it later when i make another map :smiley: