IMaterial.SetMaterialVector

From GMod Wiki

Jump to: navigation, search
Function
Syntax Material:SetMaterialVector( String parameter, Vector value )
Description:
Sets the materials parameter to a specific value.
Returns: nil
In Object: Material
Realm: NewerClient.png
BBCode Link: [b][url=http://wiki.garrysmod.com/?title=IMaterial.SetMaterialVector]IMaterial.SetMaterialVector [img]http://wiki.garrysmod.com/favicon.ico[/img][/url][/b]



Examples

DescriptionEnables Pong on the Poison Headcrab material
Used onNewerClient.png
Code
local mymatpath = Material( "models/HEADCRAB_BLACK/Blackcrab_sheet" )
mymatpath:SetMaterialInt( "$phong", 1 )
mymatpath:SetMaterialInt( "$phongexponent", 18 )
mymatpath:SetMaterialInt( "$phongboost", 1 )
mymatpath:SetMaterialVector( "$phongfresnelranges", Vector( 1.184, 1.472, 1.581 ) )
OutputN/A


Additional Notes

"$phongfresnelranges"	"[1.1 1.1 1.1]"

See Also

Personal tools
Namespaces
Variants
Actions
Navigation
Lua Scripting
Functions
Hooks
Toolbox