The Inspector Window
检视窗口
The inspector in its default position in Unity
Unity中检视面板的默认位置
Inspecting Game Objects
检视游戏对象
The showing a typical Game Object and its components
一个典型游戏对象和它组件的显示
The Inspector is used to view and edit the properties and settings of Game Objects, Assets, and other preferences and settings in the Editor.
检视面板用于显示和编辑游戏对象,资源和编辑器的首选项和其他设置的属性和设置.
When you select a GameObject in the Hierarchy or Scene View, the Inspector will show the Properties of all Components and Materials on that object and allow you to edit them. The image above shows the inspector with the default 3D camera GameObject selected. In addition to the object’s position, rotation and scale values, all the properties of the camera are available to edit.
当你在层级或场景视图上选择一个游戏对象,检视面板将显示此对象上的所有组件和材质并允许你去编辑它们.上图显示了默认3D摄像机在检视面板上的样子.除了对象的位置,旋转和缩放数值,所有摄像机属性也都可以编辑.
Inspecting Script Variables
检视脚本变量
Inspector showing a GameObject several custom scripts attached, and their public properties available to edit.
检视面板显示了几个附着在一个游戏对象上的几个自定义脚本和它们可编辑的公共属性.
When Game Objects have custom Script components attached, the public variables of that script are also shown in the inspector and can be viewed and edited like the properties of Unity’s built-in components. This allows you to set parameters and default values in your scripts easily without modifying the code.
当游戏对象上附着有自定义脚本组件,脚本的公共变量也会显示在检视面板上,可被预览和编辑就像Unity的内建组件属性一样.这让你可以方便的设置你的脚本的参数和默认数值而无需更改代码.
Inspecting Assets
检视资源
Inspector showing the import settings for a texture
检视面板上显示了贴图的导入设置
When an Asset is selected in your Project Window, the Inspector will show you the settings related to how that asset is imported and used at runtime. Each type of asset will have a different arrangement of settings. Below are some examples of the inspector showing the import settings for other asset types:
当你在项目窗口选中了一个资源,检视面板将给你显示关于此资源的导入和使用设置.每一种资源都有不同的设置布局.下面是检视面板显示其他资源类型的一些例子:
Inspector showing the import settings for an FBX file containing 3D
Models
检视面板显示了一个包含3D模型的FBX文件的导入设置.
Inspector showing the import settings for an audio file
检视面板显示了一个声音文件的导入设置.
Inspector showing the import settings for a Material Asset
检视面板显示了一个材质资源的导入设置
Project Settings
项目设置
Inspector showing the “Tags and Layers” Project Settings panel
检视面板显示了”标签和图层”项目设置面板.
When you select any of the Project Settings categories (found under: Editor -> Project Settings), those settings will be displayed in the inspector. Find out more about these on theSettings Managers page.
当你选择任何项目设置类型(在这里找:编辑器>项目设置),这些设置将会在检视面板上显示.查看更多关于此参考”设置管理”页面.