light errors - my lights turn off based on player position

S

seagoat

Guest
I've been working on this map for a while and trying to ignore the problem, but it won't go away:

If I strip everything down and have just one light (light, light_spot, either one), it'll show up but will turn off or on depending on what my character does. This isn't a max distance thing, because if I move my mouse (change my view angle), it'll change as well.

I really tried to find someone with a similar problem before posting this, hopefully someone knows what's going on. Thanks!

-Ben

P.S. - Please don't reply to a post if you don't actually have an answer, it makes it look like it's been answered and I'll have to repost to get a reply. Thank you.
 
I think I've seen a similar problem before. The mapper had a leak; VIS and RAD weren't running properly.

[edit: I apologize, it looks like you had this exact thread here, in the same forum, no less. Shame on you. IT IS ALWAYS BETTER TO POST IN AN EXISTING THREAD THAN TO START A NEW ONE!]
 
i had the same problem but only with certain textures, it seems that those textures doesn't get RAD rendered or something and light up dependent on which vis group is visible or something. I can't explain in any other way cause some other textures did work properly but some other in the exact place gave that buggy appearance what you are describing. Try some different textures
 
for the lights - it could be a hole in the map, but that usually causes a different problem, so most likely not. It probably has something to do with Vis or Rad.

Post your compile log, that should help figure out the problem.

for the textures - textures that flicker and that don't appear propperly are textures that aren't meant for maps. They are model textures from some prop, so you will need to change the texture to fix this problem.
 
compile log

Thanks for the replies, guys. Here's my compile log, in case you can see something in here. Despite finding a light leak and fixing it, the problem is still happening (it seems to be less frequent with spotlights than regular, but it still messes up with them).

My textures are all converted properly, as far as I know, but is there anything besides proper dimensions (128, 512, etc.) and running VTEX that I should know? I am using transparency on one texture that's a decal, but generally pretty standard stuff.




** Executing...
** Command: "c:\program files\valve\steam\steamapps\seagoat\sourcesdk\bin\vbsp.exe"
** Parameters: -game "c:\program files\valve\steam\steamapps\seagoat\half-life 2\hl2" "C:\Program Files\Valve\Steam\SteamApps\seagoat\sourcesdk_content\hl2\mapsrc\8H_cafe_052105_b"

Valve Software - vbsp.exe (Jan 19 2005)
2 threads
materialPath: c:\program files\valve\steam\steamapps\seagoat\half-life 2\hl2\materials
Loading C:\Program Files\Valve\Steam\SteamApps\seagoat\sourcesdk_content\hl2\mapsrc\8H_cafe_052105_b.vmf
fixing up env_cubemap materials on brush sides...
ProcessBlock_Thread: 0...1...2...3...4...5...6...7...8...9...10 (0)
ProcessBlock_Thread: 0...1...2...3...4...5...6...7...8...9...10 (0)
Processing areas...done (0)
Building Faces...done (0)
Chop Details...done (0)
Find Visible Detail Sides...done (0)
Merging details...done (0)
FixTjuncs...
PruneNodes...
WriteBSP...
done (0)
writing C:\Program Files\Valve\Steam\SteamApps\seagoat\sourcesdk_content\hl2\mapsrc\8H_cafe_052105_b.prt...done (0)
Creating default cubemaps for env_cubemap using skybox sky_wasteland02...
Run buildcubemaps in the engine to get the correct cube maps.
Finding displacement neighbors...
Finding lightmap sample positions...
Displacement Alpha : 0...1...2...3...4...5...6...7...8...9...10
Building Physics collision data...
done (1) (61406 bytes)
Emitting linux collision data (use -nolinuxdata to disable).
Building Physics collision data...
done (0) (61406 bytes)
Placing detail props : 0...1...2...3...4...5...6...7...8...9...10
Writing C:\Program Files\Valve\Steam\SteamApps\seagoat\sourcesdk_content\hl2\mapsrc\8H_cafe_052105_b.bsp
2 seconds elapsed
Memory leak: mempool blocks left in memory: 48
Memory leak: mempool blocks left in memory: 2

** Executing...
** Command: "c:\program files\valve\steam\steamapps\seagoat\sourcesdk\bin\vvis.exe"
** Parameters: -game "c:\program files\valve\steam\steamapps\seagoat\half-life 2\hl2" "C:\Program Files\Valve\Steam\SteamApps\seagoat\sourcesdk_content\hl2\mapsrc\8H_cafe_052105_b"

Valve Software - vvis.exe (Dec 15 2004)
2 threads
reading c:\program files\valve\steam\steamapps\seagoat\sourcesdk_content\hl2\mapsrc\8H_cafe_052105_b.bsp
reading c:\program files\valve\steam\steamapps\seagoat\sourcesdk_content\hl2\mapsrc\8H_cafe_052105_b.prt
384 portalclusters
1350 numportals
BasePortalVis: 0...1...2...3...4...5...6...7...8...9...10 (1)
PortalFlow: 0...1...2...3...4...5...6...7...8...9...10 (58)
Optimized: 104 visible clusters (0.00%)
Total clusters visible: 118702
Average clusters visible: 309
Building PAS...
Average clusters audible: 383
visdatasize:39399 compressed from 36864
writing c:\program files\valve\steam\steamapps\seagoat\sourcesdk_content\hl2\mapsrc\8H_cafe_052105_b.bsp
59 seconds elapsed

** Executing...
** Command: "c:\program files\valve\steam\steamapps\seagoat\sourcesdk\bin\vrad.exe"
** Parameters: -game "c:\program files\valve\steam\steamapps\seagoat\half-life 2\hl2" "C:\Program Files\Valve\Steam\SteamApps\seagoat\sourcesdk_content\hl2\mapsrc\8H_cafe_052105_b"

Valve Software - vrad.exe (Mar 8 2005)
----- Radiosity Simulator ----
2 threads
[Reading texlights from 'lights.rad']
[45 texlights parsed from 'lights.rad']

Loading c:\program files\valve\steam\steamapps\seagoat\sourcesdk_content\hl2\mapsrc\8H_cafe_052105_b.bsp
1138 faces
17295 square feet [2490508.00 square inches]
0 displacements
0 square feet [0.00 square inches]
1138 patches before subdivision
1142 patches after subdivision
1 direct lights
BuildFacelights: 0...1...2...3...4...5...6...7...8...9...10 (0)
BuildVisLeafs: 0...1...2...3...4...5...6...7...8...9...10 (4)
transfers 20371, max 55
transfer lists: 0.2 megs
GatherLight: 0...1...2...3...4...5...6...7...8...9...10 (0)
Bounce #1 added RGB(0, 0, 0)
Build Patch/Sample Hash Table(s).....Done<0.0001 sec>
FinalLightFace: 0...1...2...3...4...5...6...7...8...9...10 (0)
FinalLightFace Done
Ready to Finish
0 of 0 (0% of) surface lights went in leaf ambient cubes.
ComputePerLeafAmbientLighting: 0...1...2...3...4...5...6...7...8...9...10

Object names Objects/Maxobjs Memory / Maxmem Fullness
------------ --------------- --------------- --------
models 2/1024 96/49152 ( 0.2%)
brushes 131/8192 1572/98304 ( 1.6%)
brushsides 998/65536 7984/524288 ( 1.5%)
planes 752/65536 15040/1310720 ( 1.1%)
vertexes 2573/65536 30876/786432 ( 3.9%)
nodes 601/65536 19232/2097152 ( 0.9%)
texinfos 260/12288 18720/884736 ( 2.1%)
texdata 16/2048 512/65536 ( 0.8%)
dispinfos 0/0 0/0 ( 0.0%)
disp_verts 0/0 0/0 ( 0.0%)
disp_tris 0/0 0/0 ( 0.0%)
disp_lmsamples 0/0 0/0 ( 0.0%)
faces 1138/65536 63728/3670016 ( 1.7%)
origfaces 553/65536 30968/3670016 ( 0.8%)
leaves 604/65536 33824/3670016 ( 0.9%)
leaffaces 1297/65536 2594/131072 ( 2.0%)
leafbrushes 289/65536 578/131072 ( 0.4%)
surfedges 7811/512000 31244/2048000 ( 1.5%)
edges 4330/256000 17320/1024000 ( 1.7%)
worldlights 1/8192 88/720896 ( 0.0%)
waterstrips 92/32768 920/327680 ( 0.3%)
waterverts 0/65536 0/786432 ( 0.0%)
waterindices 1680/65536 3360/131072 ( 2.6%)
cubemapsamples 0/1024 0/16384 ( 0.0%)
overlays 0/512 0/180224 ( 0.0%)
lightdata [variable] 260/0 ( 0.0%)
visdata [variable] 39399/16777216 ( 0.2%)
entdata [variable] 9040/393216 ( 2.3%)
occluders 0/0 0/0 ( 0.0%)
occluder polygons 0/0 0/0 ( 0.0%)
occluder vert ind 0/0 0/0 ( 0.0%)
detail props [variable] 1/12 ( 8.3%)
static props [variable] 1/3058 ( 0.0%)
pakfile [variable] 9906/0 ( 0.0%)

Win32 Specific Data:
physics [variable] 61406/4194304 ( 1.5%)
==== Total Win32 BSP file data space used: 398669 bytes ====

Linux Specific Data:
physicssurface [variable] 61406/6291456 ( 1.0%)
==== Total Linux BSP file data space used: 398669 bytes ====

Total triangle count: 3239
Writing c:\program files\valve\steam\steamapps\seagoat\sourcesdk_content\hl2\mapsrc\8H_cafe_052105_b.bsp
5 seconds elapsed

** Executing...
** Command: Copy File
** Parameters: "C:\Program Files\Valve\Steam\SteamApps\seagoat\sourcesdk_content\hl2\mapsrc\8H_cafe_052105_b.bsp" "c:\program files\valve\steam\steamapps\seagoat\half-life 2\hl2\maps\8H_cafe_052105_b.bsp"
 
If your textures weren't compiled properly they just wouldn't show up in Hammer, they wouldn't cause a problem with compiling
 
What shader are you using for these custom textures? That's the first line of their .vmt file. They should usually be "LightmappedGeneric" for textures used on worldbrushes, not "VertexLitGeneric" (which should only be used for model textures and small brush entities).

If that's not it, paste a copy of one of the malfunctioning texture's vmt files here.
 
textures

well, it's not the textures that are malfunctioning, but the lights... Although you're right, apparently some or all of these textures are vertex lit:

"VertexLitGeneric"
{
"$baseTexture" "table/coffeetable"
}


Does this mean my vtex thing was configured wrong when I converted? How do I fix this?

P.S. - Some of this confusion comes from the fact that other people have worked on this project, so sometimes I dunno what they are doing when I'm not around.
 
Code:
"VertexLitGeneric"
{
"$baseTexture" "table/coffeetable"
}

That actually looks like a model texture, which would make it right.

vtex doesn't create vmt's, it just converts the tga's to vtf's
 
If you use a model texture (one using a VertexLitGeneric shader) on world brushes, the texture brightness will flash on-and-off as the player moves around the level, which would make it look like the light was flashing. I looks like that's what you're seeing.

Try changing that vmt to "LightmappedGeneric" and it should work fine. You'll probably need to recompile to get it looking correct (VertexLit brushes don't get lightmaps computed for them by the RAD process, which is why you need to recompile).
 
thanks

Badass, that worked. Thank you guys, this board has people who are far more helpful and interested than the average one, and I really appreciate the help.

-Ben
 
Back
Top