PVS Issues

I’ll just show a picture

Basically, i can’t see things when i’m not in the same leaf as them. This is a problem since i need to be able to see basiaclly the entire map at all times or else it looks shitty and props/players appear and disappear randomly.

If i add a position that’s near to the camera to the PVS would that work? I tried something similar and nothing really changed.


Even more interestingly… My visibility hook isn’t running.

function GM:SetupPlayerVisibility( ply, ent )

local pos = ply:GetShootPos() + Vector( 700, 0, 0 )

print( tostring(pos) ) //debugoverlay.Line( pos, ply:GetPos(), 9991, Color(255,0,0), true)

AddOriginToPVS( pos )


Nothing prints to console ever. Something is fucked up.

Last resort, encompass the whole map in a func_viscluster entity. I think that turns it all into one leaf.


Correction on myself:

It doesn’t make it one visleaf, it just tells them they can see each other. Should still work.

You could always set all entities render mode to always. Not sure if that’d achieve what you want, but it might.

If you don’t use any water maybe you’d get away without compiling with vvis.


Search for that on the Wiki.

Does it render if you noclip out there? Maybe you could make the characters controllable NPCs, and put the actual player in spectator mode.


Networking might be a bitch though.


Better to make a make a camera entity (like gmod_camera), spawn it where you want the player’s camera to be, and make that entity his view entity.


God dammit foszor! :suicide:

Have you tried creating some sort of entity at the same position and angles of your camera, and then using that as the players view entity?

FYI, he was calling the SetupPlayerVisibility function on the client all along.
It’s fixed now I think.

Yeah it all works now.

Oh hey Ram-



naruto headband rockin ice niggas~

To be honest, that looks like a friend of mine, but he wouldn’t do something like that. May I ask where you got the photo?