UnityEditor.TerrainInspector.ShowUpgradeTreePrototypeScaleUI C# (CSharp) 메소드

ShowUpgradeTreePrototypeScaleUI() 공개 메소드

public ShowUpgradeTreePrototypeScaleUI ( ) : void
리턴 void
        public void ShowUpgradeTreePrototypeScaleUI()
        {
            if ((this.m_Terrain.terrainData != null) && this.m_Terrain.terrainData.NeedUpgradeScaledTreePrototypes())
            {
                GUIContent content = EditorGUIUtility.TempContent("Some of your prototypes have scaling values on the prefab. Since Unity 5.2 these scalings will be applied to terrain tree instances. Do you want to upgrade to this behaviour?", EditorGUIUtility.GetHelpIcon(MessageType.Warning));
                GUILayout.BeginVertical(EditorStyles.helpBox, new GUILayoutOption[0]);
                GUILayout.Label(content, EditorStyles.wordWrappedLabel, new GUILayoutOption[0]);
                GUILayout.Space(3f);
                GUILayoutOption[] options = new GUILayoutOption[] { GUILayout.ExpandWidth(false) };
                if (GUILayout.Button("Upgrade", options))
                {
                    this.m_Terrain.terrainData.UpgradeScaledTreePrototype();
                    TerrainMenus.RefreshPrototypes();
                }
                GUILayout.Space(3f);
                GUILayout.EndVertical();
            }
        }