M MY Multiplayer: Wiki
Side
Kind

engineResetMaterialValue

Client

Drops a value the material set, or all of them, going back to what its base gives.

bool engineResetMaterialValue(material material [, string name = nil])

Parameters

NameTypeDescription
materialmaterialThe material.
namestringThe parameter or switch to drop. Without it, every value is dropped.default nil

Returns

true if something was dropped. Without name, always true.

Example

local material = engineCreateMaterial("surface")
engineSetMaterialValue(material, "roughnessFactor", 0.9)
engineResetMaterialValue(material, "roughnessFactor")

See also