- Unity 3D Game Development by Example Beginner's Guide
- Ryan Henson Creighton
- 572字
- 2021-04-09 22:51:28
This new light is really harshing our mellow. Let's move and rotate it so that it casts light a little less blazingly.
- Ensure that the Directional Light is still selected. If you deselected it, click on the Directional Light label in the Hierarchy panel.
- In the Inspector panel, change the light's position to move it up and in front of our Scene. Enter 0 for the X position, 4 for the Y position, and -4 for the Z position. Moving a Directional Light like this does not alter its intensity, but we're just making sure it's within reach in the Scene view.
- Rotate the light so that it shines down on the objects. Enter a value of 44 for the light's X Rotation in the Inspector panel.
- Now, the light is casting its sunny rays a bit more naturally on our Scene.

If you're feeling adventurous, now's a great time to get a better feel for these virtual lights. Switch to the rotate mode by using the controls at the top-left of the screen, or press the E key on your keyboard. You can freely rotate the light around to see how it affects your objects.

Switch to move mode by clicking on the Move icon or by pressing W on the keyboard. Click on the Transform gizmo to move the light around the scene. How does moving the light affect the way your objects appear?
Kill the light by pressing Delete on the keyboard (Command + Delete if you're on a Mac). Add one of the other two types of lights a spotlight or a point light by clicking on GameObject | Create Other and choosing another light. You can also change an existing light's type in the Type drop-down in the Inspector panel. What's the difference between the light you chose and the Directional Light? Move the new light all around to get a sense of how each light type treats your objects slightly differently.
Here are the differences between the lights in a nutshell:
- Directional light: This light can travel an infinite distance and illuminate everything in the Scene. This kind of light works like the sun.
- Point light: These lights start at a point in 3D space and shine all around like a lightbulb. Unlike directional lights, point lights have a range anything outside of that range doesn't get lit.
- Spotlight: Spotlights are cone-shaped. They have a range and a direction. Objects outside a spotlight's cone don't get lit by that light.
- Ambient: This is the default type of lighting that you see in your Scene, without adding any light Game Objects. Ambient lighting is the most efficient, but it's also the most boring. You can crank the level of ambient lighting in your Scene up and down by fiddling with the render settings (Edit | Render Settings). Try clicking on the Ambient Light swatch to cast a creepy, bright green glow over your entire Scene.

If this lighting stuff really revs you up, check out all of the settings and things to fiddle with within the Inspector panel when you select a light. You can get more information on what these and any other Component settings do by clicking on the blue book icon with the question mark on it in each Component section in the Inspector panel.
- GIMP 2.6 cookbook
- Hi!扁平化Photoshop扁平化用戶界面設計教程
- Django 1.2 E/commerce
- Excel數據管理:不加班的秘密
- 3ds Max 2015中文版從入門到精通
- 中文版After Effects CC 2018 動漫、影視特效后期合成秘技
- Elgg Social Networking
- Visio圖形設計從新手到高手(兼容版)
- iPad Procreate風格繪畫之美
- 好用,Excel數據處理高手
- 中文版3ds Max 2016/VRay效果圖制作實戰基礎教程(全彩版)
- WordPress MU 2.8: Beginner's Guide
- Photoshop后期強:多重曝光專業技法寶典
- SolidWorks 2017基礎與實例教程
- Revit建模進階標準教程(實戰微課版)