Light and Materials
Tutorial
·
Beginner
·
+0XP
·
10 mins
·
(54)
Unity Technologies

You are almost done, as behaviours are set now we are just going to add visual effects and make everything look like we are in space.
Languages available:
1. Make the sun emit light
In space the light is actually coming from the sun. First delete the Directional Light that is by default inside your scene. Now let’s create the light coming from the sun. Right-click in the Hierarchy and select Light > Point Light.
Point lights have a sphere shape and emit light in all directions just like the sun. Place it at 0, 0, 0 like the sun then make it light up to Neptune by changing its Range inside the Inspector to 5500. You can also change the color and the intensity if you want. Keep the mode to “Realtime” because our planets will be moving and reacting to the light in realtime.

Point Light parameters
The sun light can be seen on the other planets but it may not seem that the sun is actually emitting light. For this we are going to change its material to one that emits light. Look for the ‘Sun’ provided with the tutorial. Select the sun and in the inspector change its Material by this one:

Assigning the Sun material
If you check the settings of the Material (by selecting the Material inside the Project window), the property ‘Emissive’ is what makes it look like emitting light:

Finally go to Prefabs and drag the SunSurface one inside the 'Visuals' on the sun. This prefab is a Particle System already set for simulating the activity on the sun's surface:

Sun Surface particle system
Press play and see how particles start to appear on the surface of the sun.
2. Create a space environment
First let’s make the environment dark. Go to Window > Rendering > Lighting Settings.

Here you can change the Skybox Material. The Skybox is like a box around your scene, drawing the sky and the ground. Change the material by the one provided with the tutorial, called “SpaceSkybox”.
Skybox
The background of your scene should be completely dark, if you Play and test inside your headset you will see a subtle gradient around the horizon.
If you go to the settings of the material you will see that it is a Skybox/Procedural type of material, you can play around with the parameters and see how it changes the whole scene.
Now let's add some starts. Go to SolarSystem > Prefabs and drag the Stars into your hierarchy. This is a particle system from Unity, set to simulate stars inside your scene. If you select it in the Hierarchy they start the simulation:
3. Additional effects
We also provide some sound effects for the Project that you can use to indicate to the user when a planet started its revolution and when he/she is being ported to the next planet. Sound is very important to achieve a good immersive experience!
You can check the SolarSystemFull scene to see how sound has been implemented:

And now that you know how to create interactivity you can test and adjust until you are happy with your experience.
And you are done!