Adding _skybox caused strange light leaks


(codey_) #1

Hi all!

I’m a bit stumped at this. On my oildepot map I’ve sofar used a standard skybox but for a couple of reasons I wanted to use the _skybox feature.
Now some strange light leaks appears.

You see the light on the ground around the building which isn’t there when having a basic skybox with shader.
The building is structural, walls, floor and roof. Edges are mitred to minimize hidden textured surfaces. The ground is detail. I’ve tried the following:

  • adding ‘shadow’ brushes inside the walls.
  • extended the walls below the ground level and still the light.
  • replaced the caulk texture with a black one on the underside of the floor brush (the one flush against ground)
    Now I’m going to
  • try make the floor go lower than the ground instead of being flush on it and see what that does.
  • make the ground just around the building structural. For vis time reasons I’ve sofar had it as detail.

However I also get these strange light leaks inside the house:

Note the light on the legs of the chair (.md3 model) and along the wall in the background. And I get similar bugs in another building.
So if somebody has a idea on how to fix this generally instead of editing brushes I’d be most grateful.
I’m using GTKRadiant 1.4.0 and q3map2 2.5.11 (last versions available for mac). This is my sky shader:

textures/codey1/oilbox01
{
	nopicmip
	qer_editorimage textures/codey1/oilbox01.tga
	q3map_lightRGB 0.784 0.816 1
	surfaceparm sky
	surfaceparm nolightmap
	surfaceparm noimpact
	surfaceparm nodlight
	q3map_sunExt 1 .89 .7 90 175 40 3 16
	q3map_lightmapFilterRadius 0 8
	q3map_skyLight 100 3
	q3map_backsplash 0 23
	skyparms env/codey1/oilbox02 - -
}

Worldspawn lightmapscale is 2. I’ve tried lowering it but I only got a smaller leak and bsp got a bit big then. The floor inside is a func_group with lightmapscale 0.5

cheers


(Gringo Starr) #2

You can put a smaller lightmapscale on certain brushes. Add them to a func_group, and give it a key of “_lightmapscale” “x.x” (.5 for example). It will still increase the BSP, but if used sparingly, it can have good results.


(codey_) #3

Yup, forgot to mention I tried that on the ground - I cut up the brush to just have it on the area closest to the house and tested - had to bring it down to 0.1 to make it nearly go away. So not practical unfortunately and I got a lot of these leaks, mostly much smaller spots here and there.

I really don’t get why this happens with a _skybox but not with a normal sky shader on the hull.

cheers


(codey_) #4

Aaawww shucks - I just found this in the 2.5.12 notes

“- Fixed bug in _skybox maps where sunlight was leaking through brushes. Thanks pjw!”

Looks like I’m out of luck here. :banghead:

cheers


(codey_) #5

ydnar to the rescue!

He told me to caulk the box surrounding the _skybox instead of having the sky shader on it and lo and behold - the leaks went away. :moo:

Big thanks! :clap: