[SOLVED] Transparent effect don't work anymore

Hello again, i had this code, but seems it doesn’t work anymore
this.model.model.model.meshInstances[0].material.setParameter(‘material_opacity’, 0.5);

Hi @ayrin,

For that to work you need to make sure the opacity shader chunk is included in the material shader.

The easiest way to do that is to change the initial opacity of your material e.g. from 1.0 to 0.999. If the value is not equal to the default one, the engine will automatically include the opacity shader chunk.

Thanks a lot @Leonidas will try that at once.

@Leonidas that works nice, the bothersome thing is that i have to do that on every material applied to the players. But it’s fine since it works. Thanks a lot.

Well, you can automate it in a script in your initialize method, do this once for each material:

material.opacity = 0.999;