Gamemode.SetupPlayerVisibility

From GMod Wiki

Jump to: navigation, search
Event Hook
Hook NameSetupPlayerVisibility
SyntaxGM:SetupPlayerVisibility( Player Player, Entity Viewentity )
DescriptionSetupPlayerVisibility is called as the game is setting up the PVS. This can be used to do remote viewing.
ReturnsNil
Lua StateNewerServer.png
BBCode[b][url=wiki.garrysmod.com/?title=Gamemode.SetupPlayerVisibility]Gamemode.SetupPlayerVisibility [img]http://wiki.garrysmod.com/favicon.ico[/img][/url][/b]


Examples

DescriptionThis example adds the point (0,0,0) to the PVS.
Used onNewerServer.png
Code
function mySetupVis( ply, viewent )
	AddOriginToPVS( Vector(0,0,0) )
end
hook.Add( "SetupPlayerVisibility", "mySetupVis", mySetupVis )
OutputN/A

Additional Notes

See Also


Personal tools
Namespaces
Variants
Actions
Navigation
Lua Scripting
Functions
Hooks
Toolbox