What it does
material.assign takes matId and meshId.
Signature
material.assign(matId, meshId)Arguments
matIdmeshId
Example · generated
function start() { material.createStandard('standard'); material.assign('standard', 'standard');}material.createStandard is there to give the call something to act on; material.assign is the line that matters. The code sits in start(), which the engine calls once, when the entity spawns.