public override void OnInspectorGUI()
        {
            cycle.Profile = JEditorCommon.ScriptableObjectField <JDayNightCycleProfile>("Profile", cycle.Profile);
            profile       = cycle.Profile;
            if (cycle.Profile == null)
            {
                return;
            }

            DrawSceneReferencesGUI();
            DrawTimeGUI();
            EditorGUI.BeginChangeCheck();
            DrawSkyGUI();
            DrawStarsGUI();
            DrawSunGUI();
            DrawMoonGUI();
            DrawHorizonCloudGUI();
            DrawOverheadCloudGUI();
            DrawDetailOverlayGUI();
            DrawEnvironmentReflectionGUI();
            if (EditorGUI.EndChangeCheck())
            {
                EditorUtility.SetDirty(profile);
            }
        }
Exemplo n.º 2
0
        public override void OnInspectorGUI()
        {
            sky.Profile = JEditorCommon.ScriptableObjectField <JSkyProfile>("Profile", sky.Profile);
            profile     = sky.Profile;
            if (sky.Profile == null)
            {
                return;
            }
            dnc = sky.GetComponent <JDayNightCycle>();

            DrawSceneReferencesGUI();
            EditorGUI.BeginChangeCheck();
            DrawSkyGUI();
            DrawStarsGUI();
            DrawSunGUI();
            DrawMoonGUI();
            DrawHorizonCloudGUI();
            DrawOverheadCloudGUI();
            DrawDetailOverlayGUI();
            DrawUtilitiesGUI();

            if (EditorGUI.EndChangeCheck())
            {
                profile.UpdateMaterialProperties();
                EditorUtility.SetDirty(sky);
                EditorUtility.SetDirty(profile);
            }

            DrawAddDayNightCycleGUI();
        }
Exemplo n.º 3
0
        public override void OnInspectorGUI()
        {
            //sky.Profile = EditorGUILayout.ObjectField("Profile", sky.Profile, typeof(JSkyProfile), false) as JSkyProfile;
            sky.Profile = JEditorCommon.ScriptableObjectField <JSkyProfile>("Profile", sky.Profile);
            profile     = sky.Profile;
            if (sky.Profile == null)
            {
                return;
            }

            DrawSceneReferencesGUI();
            EditorGUI.BeginChangeCheck();
            DrawSkyGUI();
            DrawStarsGUI();
            DrawSunGUI();
            DrawMoonGUI();
            DrawHorizonCloudGUI();
            DrawOverheadCloudGUI();
            DrawDetailOverlayGUI();
            DrawUtilitiesGUI();

            if (EditorGUI.EndChangeCheck())
            {
                profile.UpdateMaterialProperties();
            }

            DrawAddDayNightCycleGUI();
        }