[SOLVED] Is it possible to make skybox transparent, but keep its lights?

In fact, I found a way to implement it after reading the source code of scene.js:

app.scene._skyboxCubeMap = null;

This is using the internal api to remove the skybox, but keep its lights.
I want to know if there any official way to implement it?

One more question, can I set the skybox without loading the textures ? What I need is the lights, not the cube map…

Yes. Simply don’t set a cubemap as a sky box and, instead, set the cubemap on the ‘Cube Map’ slot of all your materials (in the Environment section):

You can also do this in script with the cubeMap property:

material.cubeMap = myCubeMap;
1 Like

How can I implement this by the engine ?


Maybe something like this ?

Like I said, just don’t set a skybox and iterate over all your materials and do:

material.cubeMap = myCubeMap;
1 Like

Oh, I see, thank you!!