Category: Objects / Display
Since engine version: 1.0 OC
Changes the material of the calling object's mesh at runtime.
bool SetMeshMaterial(string material, int submesh);
- Name of the material to set. It needs to be loaded at engine startup, i.e. it needs to be defined in a *.material file being located in an object that was loaded.
- [opt] If the mesh is composed of multiple submeshes then this parameter can be used to specify the submesh whose material is to be changed.
SetMeshMaterial("Clonk_Body_EyesClosed"); Schedule("SetMeshMaterial(\"Clonk_Body\")", 5);
Makes a clonk blink.
See also: GetMeshMaterial