Regular API function


Description Sets the material ID of a specific shape. You might have to also call simResetDynamicObject for changes to take effect. See also simGetMaterialId and simGetShapeMaterial.
C synopsis simInt simSetShapeMaterial(simInt shapeHandle,simInt materialId)
C parameters
shapeHandle: the handle of the shape. See also simGetObjectHandle.
materialId: the ID of the material. See also simGetMaterialId.
C return value
-1 in case of an error.
Lua synopsis number result=simSetShapeMaterial(number shapeHandle,number materialId)
Lua parameters
Same as C-function
Lua return values
Same as C-function

All regular API functions on one page