this.app.assets.loadFromUrl("https://www.vrnewg.com/wth/my_model/xx.glb", "container", function (err, asset)
{
entity = asset.resource.instantiateRenderEntity();
selfself.entity.addChild(entity);
entity.setLocalPosition(0, 0, 0);
entity.setLocalScale(0.01,0.01,0.01);
var models = entity.findComponents("render");
for(var i = 0;i<models.length;i++)
{
if(models[i].entity.name=="QSFLTQSXX_Model_0")
{
console.log(i);
selfself.loadMaterial(models[i].entity);
}
}
});
asset.resource.instantiateRenderEntity();
Uncaught TypeError: Cannot read properties of undefined (reading ‘instantiateRenderEntity’)
It worked a few months ago, but now it doesn’t