Render.SetLightingOrigin

From GMod Wiki

Jump to: navigation, search
Function
Syntax Render.SetLightingOrigin( Vector lighting origin )
Where is this used?
Description:
Sets the origin of the lighting.
Returns: nil
Part of Library: render
Realm: NewerClient.png
BBCode Link: [b][url=http://wiki.garrysmod.com/?title=Render.SetLightingOrigin]Render.SetLightingOrigin [img]http://wiki.garrysmod.com/favicon.ico[/img][/url][/b]



Examples

DescriptionThis was taken from the DModelPanel code.
Used onNewerClient.png
Code
 
    render.SuppressEngineLighting( true )
    render.SetLightingOrigin( self.Entity:GetPos() )
    render.ResetModelLighting( self.colAmbientLight.r/255, self.colAmbientLight.g/255, self.colAmbientLight.b/255 )
    render.SetColorModulation( self.colColor.r/255, self.colColor.g/255, self.colColor.b/255 )
    render.SetBlend( self.colColor.a/255 )
 
OutputWill set the lighting of the model.


See Also

Personal tools
Namespaces
Variants
Actions
Navigation
Lua Scripting
Functions
Hooks
Toolbox